Instrument Control (GPIB, Serial, VISA, IVI)

cancel
Showing results for 
Search instead for 
Did you mean: 

serial poll on GPIB

I'm programming a LabVIEW code to control a Network Analyzer over GPIB. I'm trying to read some data from the network analyzer when the data is ready. Unfortunately, the command for asking for that data is not an operation complete command (OPC) compatible. I read the article Serial Polling and SRQ Servicing with NI-488.2 Software and LabVIEW on this website and got an idea about using a serial polling method by putting Wait For GPIB RQS.vi into my code, but it just reads -1 back on the status byte (which means it's timeout before RQS is issued). Does the serial poll method works only with the OPC command? Please advice me how to read data when it's ready.
Download All
0 Kudos
Message 1 of 2
(3,758 Views)
Hi,

The instrument's user manual is the ultimate reference on how the instrument reports its status.

I noticed in your VIs that you are trying to set the Service request enable register to bit 4 (Message Available). I think that is the right setting, but you are sending the wrong command.

The IEEE 488.2 command to access the SRE is *SRE and you need to send the complete register value. To set the MAV bit you need to send *SRE 0x10

Hope this helps.

DiegoF.
National Instruments.
0 Kudos
Message 2 of 2
(3,757 Views)