Chapter 9
159
Measurement Applications (Sample Programs)
Detecting Error Occurrence using SRQ (HT Basic)
9.
M
easu
rem
ent
Applica
tio
ns
(S
amp
le
Prog
ra
ms)
Example 9-17
Error occurrence detection using SRQ (srq_err.bas)
10 DIM Buff$[9],Err_mes$[50]
20 INTEGER Err_no
30 !
40 ASSIGN @Agt4981a TO 717
50 !
60 OUTPUT @Agt4981a;"*ESE 60"
70 OUTPUT @Agt4981a;"*SRE 32"
80 OUTPUT @Agt4981a;"*CLS"
90 OUTPUT @Agt4981a;"*OPC?"
100 ENTER @Agt4981a;Buff$
110 !
120 ON INTR 7 GOTO Err_proc
130 ENABLE INTR 7;2
140 OUTPUT @Agt4981a;":CALC1:FORM CS"
150 PRINT "Primary Parameter Setting: CS"
160 OUTPUT @Agt4981a;":CALC2:FOR Q"
170 PRINT "Secondary Parameter Setting: Q"
180 OUTPUT @Agt4981a;"*OPC?"
190 ENTER @Agt4981a;Buff$
200 GOTO Skip_err_proc
210 Err_proc: OFF INTR 7
220 OUTPUT @Agt4981a;";:SYST:ERR?"
230 ENTER @Agt4981a;Err_no,Err_mes$
240 PRINT "Error occurred!!"
250 PRINT " No:";Err_no,"Description: "&Err_mes$
260 PRINT "PROGRAM INTERRUPT!!"
270 GOTO Prog_end
280 Skip_err_proc: PRINT "PROGRAM DONE."
290 Prog_end: END
Содержание E4981A
Страница 2: ......
Страница 20: ...18 Chapter1 Making Effective Use of This Manual How To Use This Manual ...
Страница 60: ...58 Chapter4 Preparation for Accurate Measurement Executing Correction Using the Cable Correction Function ...
Страница 88: ...86 Chapter7 Sorting Based on Measured Result Comparator Function Sample Program ...
Страница 162: ...160 Chapter9 Measurement Applications Sample Programs Detecting Error Occurrence using SRQ HT Basic ...
Страница 376: ...374 AppendixE Error Messages Warning Messages WARNING ...
Страница 382: ......
Страница 383: ...This information is subject to change without notice Keysight Technologies 2008 2014 Edition 2 August 2014 E4981 90001 ...