
Chapter 6
77
Reading Out Measured Result
Reading Out Measured Result
6. R
ead
ing
out
Mea
s
u
re
d
Res
u
lt
Sample program
Example 6-7 shows a sample program to read out the measured result using the data buffer.
This program is stored on the sample program disk under the filename “data_buf.bas.”
This program executes measurement 50 times, reads out the results of the 50 measurements
in batch using data buffer 3, and then displays this information.
The program is detailed below.
Lines 40 to 50
Sets the GPIB address.
Line 70
Assigns the number of measurements to be fed into the data buffer (50
times) to the Point variable.
Line 90
Sets the data transfer format to the binary format.
Lines 110 to 120 Turns ON the trigger system continuous startup and sets the trigger
mode to the GPIB trigger.
Lines 140 to 150 Reads out the ON/OFF state of the comparator function and assigns it
to the Comp_flag variable.
Line 170
If the Comp_flag value is 1 (the comparator function is ON), redefines
the size of the array data so that the number of data items for each
measurement is 4.
Line 190
If the Comp_flag value is not 1 (the comparator function is OFF),
redefines the size of the array data so that the number of data items for
each measurement is 3.
Lines 220 to 230 Sets the number of measurements to be fed into the data buffer to
‘Point’ and makes the setup feed the measured result into the data
buffer.
Lines 270 to 310 Repeats the measurement until data buffer 3 becomes full.
Lines 350 to 410 Reads out data buffer 3.
Lines 470 to 530 If the Comp_flag value is 1 (the comparator function is ON), displays
the measurement status, measured primary parameter value, measured
secondary parameter value, and comparator sorting result.
Lines 550 to 610 If the Comp_flag value is not 1 (the comparator function is OFF),
displays the measurement status, measured primary parameter value,
and measured secondary parameter value.
Example 6-7
Reading out measured result using data buffer (data_buf.bas)
10
DIM Buff$[9],Digit$[1],Read_form$[9],Num_of_byte$[9],Img$[50]
20
REAL Data(1:1000,1:4)
30
INTEGER Point,Comp_flag,Cond_reg
40
ASSIGN @Binary TO 717;FORMAT OFF
50
ASSIGN @Agt4288a TO 717
60
!
70
Point=50
80
!
90
OUTPUT @Agt4288a;":FORM REAL"
100
!
110
OUTPUT @Agt4288a;":INIT:CONT ON"
120
OUTPUT @Agt4288a;":TRIG:SOUR BUS"
130
!
140
OUTPUT @Agt4288a;":CALC:COMP?"
Содержание 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 ...