Sending Samples To Memory; Sending Samples To The Controller - Agilent Technologies 3458A User Manual

Hide thumbs Also See for 3458A:
Table of Contents

Advertisement

Sending Samples to
Memory
10OPTION BASE 1
20REAL Samp(l:200) BUFFER
30ASSIGN @Dvm TO 722
40ASSIGN @Samp TO BUFFER Samp(*)
50OUTPUT @Dvm;"PRESET FAST"
60OUTPUT @Dvm;"MEM FIFO"
70OUTPUT @Dvm;"MFORMAT SINT"
80OUTPUT @Dvm;"OFORMAT DREAL"
90OUTPUT @Dvm;"SSDC 10"
100OUTPUT @Dvm;"SWEEP 5E-6,200"
110TRANSFER @Dvm TO @Samp;WAIT
120FOR I=1 TO 200
130 IF ABS(Samp(I))=lE+38 THEN
140
PRINT "Overload Occurred"
150 ELSE
160
Samp(I)=DROUND(Samp(I),5)
170
PRINT Samp(I)
180 END IF
190NEXT I
200END
Sending Samples to
the Controller
144
Chapter 5 Digitizing
source event and the first sample in each burst; the default delay for
sub-sampling is 0 seconds.)
When samples are sent directly to reading memory (MEM FIFO command),
the multimeter automatically re-orders the samples producing a composite
waveform. For example, in the following program, the sub-sampled data is
sent to reading memory using the required SINT memory format. The
multimeter places the samples in memory in the corrected order. The samples
are then transferred to the controller using the DREAL output format (when
placing sub-sampled data in reading memory first, you are not restricted to
using the SINT output format).
!COMPUTER ARRAY NUMBERING STARTS AT 1
!CREATE BUFFER ARRAY
!ASSIGN MULTIMETER ADDRESS
!ASSIGN BUFFER
!TARM SYN, TRIG AUTO, DINT FORMATS
!FIRST-IN-FIRST-OUT READING MEMORY
!SINT MEMORY FORMAT
!DOUBLE REAL OUTPUT FORMAT
!SUB-SAMPLING, 10V RANGE, DC-COUPLED
!5µs EFF. INTERVAL, 200 SAMPLES
!TRANSFER SAMPLES TO CONTROLLER BUFFER
!DETECT OVERLOAD
!PRINT OVERLOAD MESSAGE
!IF NO OVERLOAD OCCURRED:
!ROUND TO 5 DIGITS
!PRINT EACH SAMPLE
When samples are sent directly to the controller, an algorithm must be used
to re-order the samples and produce the composite waveform. The
SSPARM? command returns three parameters for the algorithm. The first
parameter returned is the number of bursts measured that contained N
samples. The second parameter returned is the number of bursts measured
that contained N-1 samples. The third parameter returned is the value of N.
For example, assume you are sub-sampling a 10kHz signal and specify 22
samples with an effective_interval of 5µs. In this example, the multimeter
takes 2 bursts containing 6 samples each and 2 bursts containing 5 samples
each. Each burst is delayed 5µs from the previous burst. The values returned
by SSPARM? are then 2, 2, and 6.
When sub-sampling, the maximum sample rate is 50k samples per second
regardless of the specified effective_interval. (If you specify an
effective_interval of ³20µs, the multimeter is no longer sub-sampling but
direct-sampling.) When sending samples directly to the controller (using the
required SINT format which is 2-bytes per sample) the GPIB/controller must
be able to handle the data at a maximum rate of 100k-bytes per second. If
not, the multimeter generates the TRIGGER TOO FAST error.
In the program on the following page, the SSAC command is used to digitize
a 10 kHz signal with a peak value of 5V. The SWEEP command instructs

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents