Well, for whatever reason the selectors on the values are not working (it was like this the entire time, so it didn't break), I rewrote my code to use the ones you gave in your example Cs, Cp,Zs etc. but the values do not appear in the current values list unless I remove the selector from it, which obviously means the units/modes are not correctly shown, and likely means I am missing something and doing something dumb.
#cmdMode Ls Ls
FUNC:IMP:A L;FUNC:IMP:EQU SERial;
#cmdMode Lp Lp
FUNC:IMP:A L;FUNC:IMP:EQU PALlel;
#cmdMode Cs Cs
FUNC:IMP:A C;FUNC:IMP:EQU SERial;
#cmdMode Cp Cp
FUNC:IMP:A C;FUNC:IMP:EQU PALlel;
#cmdMode ECs ECs
FUNC:IMP:A ECAP;FUNC:IMP:EQU SERial;
#cmdMode Rs Rs
FUNC:IMP:A R;FUNC:IMP:EQU SERial;
#cmdMode Rp Rp
FUNC:IMP:A R;FUNC:IMP:EQU PALlel;
#cmdMode Zs Zs
FUNC:IMP:A Z;FUNC:IMP:EQU SERial;
#cmdMode Zp Zp
FUNC:IMP:A Z;FUNC:IMP:EQU PALlel;
#cmdMode DCR DCR
FUNC:IMP:A DCR
#cmdMode ESR ESR
FUNC:IMP:B ESR;[400];
#cmdMode D D
FUNC:IMP:B D;[400];
#cmdMode X X
FUNC:IMP:B X;[400];
#cmdMode Q Q
FUNC:IMP:B Q;[400];
; this one might need the handle changing, as the meter returns this: ¦È for the phase symbol
#cmdMode Angle Deg
FUNC:IMP:B THR;[400];
This is what else I am using:
#value Capacity_P F SI Cp
#value Capacity_S F SI Cs,ECs
#value Inductance H SI Ls,Lp
#value Impedance ohm SI Zs,Zp,Rs,Rp
#value ESR ohm SI ESR
#value Impedance ohm SI X
#askValuesReadFormat xsxs
#askModeMathFormat getMatch(getElement(value,1),"[0-9.+-FH]+")+getMatch(getElement(value,3),"[0-9.+-FH]+")
I tried using #modeFromValue getElement(value,0)+";"+getElement(value,2) but for whatever reason on a couple of mode it resulted in the returned readings flickering on/off a few times a second, as thought it was only seeing every other reading, I have commented that back out for the time being, as my current issue is the selector for #value not working.
Another interesting issue is that despite sending two commands at once to set the mode and series/parallel modes, the second command is being ignored by the meter, I tried using various [400] delays between the commands etc. but that didn't work, I went from [1] up to [2000] without any change, BUT if I send two commands together from the tc window instead it works, responding to the first command, then the second command shows up and the second response shows up.
I am also seeing an odd behavour with this meter where sometimes it ignores commands completely, so I have to push the button again, sometimes more than once.
This is connected via USB, in case that is of consequence.