Agilent Technologies 86120B Marine Instruments User Manual


 
4-33
Programming
Example Programs
Err_mngmt:SUB Err_mngmt
COM /Instrument/ @Mwm
DIM Err_msg$[255]
INTEGER Cme
CLEAR 7
REPEAT
OUTPUT @Mwm; "*ESR?"
ENTER @Mwm;Cme
OUTPUT @Mwm; ":SYST:ERR?"
ENTER @Mwm;Err_msg$
PRINT Err_msg$
UNTIL NOT BIT(Cme,2) AND NOT BIT(Cme,4) AND NOT BIT(Cme,5) AND Err$,"+0")
Subend:SUBEND
Set_ese:SUB Set_ese
COM /Instrument/ @Mwm
OUTPUT @Mwm; "*ESE";IVAL("00110100",2)
SUBEND
Identity:DEF FNIdentity$;
COM /Instrument/ @Mwm
DIM Identity$[50]
Identity$=""
OUTPUT @Mwm;"*RST"
OUTPUT @Mwm;"*OPC?"
ENTER @Mwm;Opc_done
OUTPUT @Mwm;"*IDN?"
ENTER @Mwm;Identity$
RETURN Identity$
FNEND