KIKUSUI Electronics Corp.
332
Waiting for Operation Complete
The *OPC command has a function for waiting for operations to complete. Operation
complete means that there are no operations that are waiting for a response from the
PCR-WE. Measurement completion requires about 110 ms. The PCR-WE is not in
the operation complete state while a measurement is ongoing. When the measure-
ment completes, if there are no other operations waiting to be completed, the PCR-
WE enters the operation complete state.
When an *OPC command is received, the product transitions to the Operation Com-
plete Command Active State (OCAS). If a measurement is completed and there are
no operations standing by, the product returns to the Operation Complete Command
Idle State (OCIS) and sets the OPC bit (bit 0) of the event status register to TRUE
(1). This information can be determined by checking the OPC bit (bit 0) of the *ESR?
query.
Next, we will show an example that starts a new measurement and sends an *OPC
command. Because the event status enable register and service request enable reg-
ister are configured to generate a service request (SRQ) in response to an operation
complete event, an SRQ is generated when a measurement is completed. The SRQ
function cannot be used if you are using the RS232 interface.
*ESE 1;*SRE 32;*CLS;:INITiate:IMMediate:ACQuire;*OPC
<Generates a service request>
If you use the *OPC? query command in place of the *OPC command, the product
transitions to the Operation Complete Query Active State (OQAS). If a measurement
is completed and there are no operations standing by, the product returns to the Op-
eration Complete Query Idle State (OQIS) and sets response data
“
1
”
(in NR1 for-
mat) in the output queue.
INITiate:IMMediate:ACQuire;*OPC?
<Reads the response>
At power-on, if you send an IEEE488 sdc/dcl, *RST, or *RCL, this product switches to
the OCIS and OQIS states.