HP (Hewlett-Packard) E1418A TV Converter Box User Manual


 
Using *OPC?
As shown, the examples have made no attempt to coordinate the program
execution with the HP E1418A module. In some cases, you may need to pause
program execution until the module has completed executing the commands.
The IEEE-488 common command
*OPC? can be used to keep the program
and the module synchronized. The
*OPC? query returns a 1 when all
programmed operations are complete. The program can wait for the
response before executing additional statements. The returned value is
unimportant (always a 1).
/* Set channel 1 voltage mode */
SOURce1:FUNCtion:MODE VOLTage
/* Set channel 1 voltage output */
SOURce1:VOLTage 5.000
/* Turn on the output */
OUTPut1 ON
*OPC?
/* enter the response */
*OPC?
is used to synchronize the program with the module since program
execution waits for the response. The command may be combined using the ;
as described under “Linking Commands” on page 62. For example,
/* Set channel 1 voltage mode */
SOURce1:FUNCtion:MODE VOLTage;*OPC?
/* enter the response */
56 Programming Examples Chapter 2