Tektronix DPO4000 Landscape Lighting User Manual


 
Status and Events
Thesamecomman
d sequence using the *WAI command for synchronization
looks like this:
/* Set up condi
tional ac quisition */
ACQUIRE:STATE OFF
SELECT:CH1 ON
HORIZONTAL:RECORDLENGTH 1000
ACQUIRE:MODE SAMPLE
ACQUIRE:STOPAFTER SEQUENCE
/* Acqu ire
waveform data */
ACQUIRE:STATE ON
/* Set up the measurement parameters */
MEASUREMENT:IMMED:TYPE AMPLITUDE
MEASUREMENT:IMMED:SOURCE CH1
/* Wait until the acquis ition is complete before taking
the mea s
urement*/
*/
*WAI
/* Take amplitude measurement */
MEASUREMENT:IMMED:VALUE
The controller can continue to write commands to the input buffer of the
oscilloscope, but the commands w ill not be processed by the oscilloscope until
all in-process OPC operations are complete. If the input buffer becomes full,
the c
ontroller will be unable to write commands to the buffer. This can cause a
time-out.
Using the BUSY Query
The BUSY? query allows you to nd out whether the oscilloscope is
bu
sy processing a command that has an extended processing time such as
single-sequence acquisition.
T
he same command sequence, using the BUSY? query for synchronization, looks
like this:
/* Set up conditional ac quisition */
ACQUIRE:STATE OFF
SELECT:CH1 ON
HORIZONTAL:RECORDLENGTH 1000
ACQUIRE:MODE SAMPLE
ACQUIRE:STOPAFTER SEQUENCE
/* Acqu ire waveform data */
ACQUIRE:STATE ON
/* Set up the measurement parameters */
MEASUREMENT:IMMED:TYPE AMPLITUDE
MEASUREMENT:IMMED:SOURCE CH1
/* Wait until the acquis ition is complete before taking
the mea surement */
While B USY keep looping
MSO4000 and DPO4000 Series Programmer Manual 3-9