Status and Events
Thesamecomman
d sequence using the *WAI command for synchronization
looks like this:
/* Set up conditional acquisition */
ACQUIRE:STATE OFF
SELECT:CH1 ON
HORIZONTAL:RECORDLENGTH 1000
ACQUIRE:MODE SAMPLE
ACQUIRE:STOPAFTER SEQUENCE
/* Acquire waveform data */
ACQUIRE:STATE ON
/* Set up the measurement parameters */
MEASUREMENT:IMMED:TYPE AMPLITUDE
MEASUREMENT:IMMED:SOURCE CH1
/* Wait until the acquisition is complete before taking
the measurement*/
*/
*WAI
/* Take amplitude measurement */
MEASUREMENT:IMMED:VALUE
The controller can continue to write commands to the input buffer of the
oscilloscope, but the commands will not be processed by the oscilloscope until
all in-process OPC operations are complete. If the input buffer becomes full,
the controller 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 find out whether the oscilloscope is
busy processing a command that has an extended processing time such as
single-sequence acquisition.
The same command sequence, using the BUSY? query for synchronization, looks
like this:
/* Set up conditional acquisition */
ACQUIRE:STATE OFF
SELECT:CH1 ON
HORIZONTAL:RECORDLENGTH 1000
ACQUIRE:MODE SAMPLE
ACQUIRE:STOPAFTER SEQUENCE
/* Acquire waveform data */
ACQUIRE:STATE ON
/* Set up the measurement parameters */
MEASUREMENT:IMMED:TYPE AMPLITUDE
MEASUREMENT:IMMED:SOURCE CH1
/* Wait until the acquisition is complete before taking
the measurement */
While BUSY keep looping
MSO4000 and DPO4000 Series Programmer Manual 3-9