Chapter 6
69
Reading Out Measured Result
Reading Out Measured Result
6. R
ead
ing
out
Mea
s
u
re
d
Res
u
lt
Example 6-4
Reading out measured result in binary transfer format using
command
(fetch_b.bas)
10
DIM Buff$[9],Digit$[1],Read_form$[9],Num_of_byte$[9]
20
REAL Pri_para,Sec_para
30
REAL Meas_stat,Comp
40
INTEGER Comp_flag
50
ASSIGN @Binary TO 717;FORMAT OFF
60
ASSIGN @Agt4288a TO 717
70
OUTPUT @Agt4288a;":FORM REAL"
80
!
90
OUTPUT @Agt4288a;":INIT:CONT ON"
100
OUTPUT @Agt4288a;":TRIG:SOUR EXT"
110
!
120
OUTPUT @Agt4288a;":CALC:COMP?"
130
ENTER @Agt4288a;Comp_flag
140
!
150
! SRQ setting
160
!
170
OUTPUT @Agt4288a;":STAT:OPER:ENAB 16"
180
OUTPUT @Agt4288a;"*SRE 128"
190
OUTPUT @Agt4288a;"*CLS"
200
OUTPUT @Agt4288a;"*OPC?"
210
ENTER @Agt4288a;Buff$
220
!
230
! Triggering and data read
240
!
250
ON INTR 7 GOTO Meas_end
260
ENABLE INTR 7;2
270
PRINT "Waiting for External Trigger!"
280 Meas_wait:
GOTO Meas_wait
290 Meas_end:
OFF INTR 7
300
OUTPUT @Agt4288a;":FETC?"
310
ENTER @Agt4288a USING "#,A";Buff$
320
ENTER @Agt4288a USING "#,A";Digit$
330
Read_form$="#,"&Digit$&"A"
340
ENTER @Agt4288a USING Read_form$;Num_of_byte$
350
IF Comp_flag=1 THEN
360
ENTER @Binary;Meas_stat,Pri_para,Sec_para,Comp
370
ELSE
380
ENTER @Binary;Meas_stat,Pri_para,Sec_para
390
END IF
400
ENTER @Agt4288a USING "#,A";Buff$
410
!
420
! Display results
430
!
440
PRINT USING "15A,X,D";"Meas. status
:",Meas_stat
450
PRINT USING "15A,X,SD.5DE";"Pri. parameter:",Pri_para
460
PRINT USING "15A,X,SD.5DE";"Sec. parameter:",Sec_para
470
IF Comp_flag=1 THEN
480
PRINT USING "15A,X,K";"Comparator
:",Comp
490
ELSE
500
PRINT USING "19A";"Comparator
: OFF"
510
END IF
520
END
Содержание 4288A
Страница 18: ...16 Chapter1 Making Effective Use of This Manual How To Use This Manual ...
Страница 102: ...100 Chapter8 Avoiding Mistakes Related to Work and Daily Checks Daily Checks executing the self test ...
Страница 212: ...210 AppendixA Manual Changes Manual Changes ...
Страница 248: ...246 AppendixB Information for Replacing 4278A with 4288A Comparison of Interfaces ...
Страница 258: ...256 AppendixC Status Reporting System Using the Status Reporting System ...
Страница 282: ...280 AppendixG 4268A vs 4288A GPIB Command Correspondence Table 4268A vs 4288A GPIB Command Correspondence Table ...
Страница 288: ...286 Index Index ...