14.06.2014 Views

R&S WinIQSIM2 Software Manual - Rohde & Schwarz

R&S WinIQSIM2 Software Manual - Rohde & Schwarz

R&S WinIQSIM2 Software Manual - Rohde & Schwarz

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

R&S ® <strong>WinIQSIM2</strong><br />

Automation of R&S <strong>WinIQSIM2</strong><br />

Remote Control Basics<br />

2. Set bit no. 5 in the SRE: *SRE 32 to enable ESB service request.<br />

3. Send the overlapped command with *OPC<br />

4. Wait for a service request<br />

The service request indicates that the overlapped command has finished.<br />

*OPC? with a service request<br />

1. Set bit no. 4 in the SRE: *SRE 16 to enable MAV service request.<br />

2. Send the overlapped command with *OPC?<br />

3. Wait for a service request<br />

The service request indicates that the overlapped command has finished.<br />

Event Status Register (ESE)<br />

1. Set the OPC mask bit (bit no. 0) in the ESE: *ESE 1<br />

2. Send the overlapped command without *OPC, *OPC? or *WAI<br />

3. Poll the operation complete state periodically (by means of a timer) using the<br />

sequence: *OPC; *ESR?<br />

A return value (LSB) of 1 indicates that the overlapped command has finished.<br />

*OPC? with short timeout<br />

1. Send the overlapped command without *OPC, *OPC? or *WAI<br />

2. Poll the operation complete state periodically (by means of a timer) using the<br />

sequence: ; *OPC?<br />

3. A return value (LSB) of 1 indicates that the overlapped command has finished. In<br />

case of a timeout, the operation is ongoing.<br />

4. Reset timeout to former value<br />

5. Clear the error queue with SYStem:ERRor? to remove the "-410, Query interrupted"<br />

entries.<br />

Using several threads in the controller application<br />

As an alternative, provided the programming environment of the controller application<br />

supports threads, separate threads can be used for the application GUI and for controlling<br />

the instrument(s) via SCPI.<br />

A thread waiting for a *OPC? thus will not block the GUI or the communication with other<br />

instruments.<br />

<strong>Software</strong> <strong>Manual</strong> 1008.0858.42 ─ 10<br />

154

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!