802BT/802R Video Test Generator User Guide 103
to wait for all preceding commands to be completed before the commands that follow *WAI
are processed. For example, sending the following command line causes a red rectangle
to be drawn and then overwritten by the colorbar image.
IMGL COLORBAR; IMGU; IMGE; RECT RED 200 200 0 0 GRAYPAT100
Note that the IMGU command merely requests that the current image be rendered
eventually, not necessarily right away nor in a single attempt. By inserting a *WAI
command after the IMGU, the generator is instructed to render the colorbar image first,
before rendering the red rectangle. This command ensures that the generator draws the
red rectangle on top of the colorbar image.
IMGL COLORBAR; IMGU; *WAI; IMGE; RECT RED 200 200 0 0 GRAYPAT100
The generator will wait until the colorbar image has been completely rendered before it
reads and executes the RECT command.
The
*WAI
command is required by the IEEE-488.2-1992 standard, but also works with
GPIB and RS-232 protocols as well.
Completion handshake
The generator returns a > prompt immediately after an FMTU, IMGU, ALLU, BOOT, INIT,
or SCAL command is received, even if these commands have not finished executing. If the
system controlling the generator must know when the process started by one of these
commands has been completed, then append *OPC? to the command string.
For example, the following command causes the generator to wait until all processes have
been completed before responding with the number 1 and sending the > prompt.
FMTL VGA_M3; IMGL FLAT; ALLU; *OPC?
The *OPC? command is required by the IEEE-488.2-1992 standard, but also works with
GPIB and RS-232 protocols as well.
Input buffer
Since some commands may take longer to execute, the 802 has an input buffer. This input
buffer is 255 characters long and can be written to by the host controller while the 802 is
busy executing or parsing previous messages. If the input buffer becomes full, the 802 will
hold off the controller until there is room in the buffer. For this reason, a program message
cannot be longer than 255 characters including terminator.