Agilent Technologies 35670A Manual page 760

Dynamic signal analyzer gpib programming
Hide thumbs Also See for 35670A:
Table of Contents

Advertisement

Example Programs
GETCAP
Comments for GETCAP
Declare an array equal to or larger than the largest time capture we expect to read. It is
130
convenient to use 1024 for one dimension of the array because the analyzer always captures data
in 1024 point blocks.
Determine if this program is running in the analyzer or an external controller and set the
150 - 190
analyzer address accordingly.
Assign path for formatted communication with the analyzer.
210
Assign path for binary communication with the analyzer.
220
Setup the analyzer to output a 100 HZ, 2 Vpk sine wave and capture 10 records of time
250 - 350
data.
Tell the analyzer to send and receive 64 bit/point (8 byte/point) data blocks.
380
Send the query asking the analyzer to send the channel 1 time capture data.
400
Enter the definite block header (a pound sign, the number of characters in the byte count,
410-420
and the byte count).
Convert the byte count to number of points and then calculate the number of records. There
440-450
are 8 bytes/point and 1024 bytes/record.
Redimension the Y data array so that it is the same size as the data we will receive.
470
Enter the Y data using the unformatted path.
500
Enter the block termination character.
530
Square the Y data using the matrix dot operator.
560
Calculate the maximum absolute value of the Y data and set the time-capture channel 1
590-600
range value to the maximum. This will maximize the dynamic range.
Calculate the number of bytes we will send to the analyzer.
620
Convert the byte value to a string. We have to use the OUTPUT statement because VAL$
630-640
would create a string with exponential notation for large values of Bytes.
Calculate the length of the Bytes$ string.
650
Output the mnemonic to send time-capture data and the definite-length block header (# symbol,
670
number of characters in the byte count, and the byte count).
Output the data block to the analyzer using the unformatted path.
690
Output an END to the analyzer to end the data block.
700
F-22

Advertisement

Table of Contents
loading

Table of Contents