Instrument Control (GPIB, Serial, VISA, IVI)

cancel
Showing results for 
Search instead for 
Did you mean: 

VISA STB request does not respect timeout setting

I scan my GPIB Bus using VISA to get the status byte and see if an instrument is connected. In this case the timemout is short since a response for a status byte should be very quick (< 100 mS).

BUT the scan takes a long time. In fact it seems to take 1 second per address, independent of the timeout setting.

I cannot use the VISA Find function since the GPIB isolator responds as a listener at all addresses. Thus I need to get a status byte for each device to see if it exists.

This does not happen unless a single instrument is hooked up to the bus???!! If there are no instruments, then the response is quick and about correct (even works down to 10 mS timout). But as soon as a single instrument is put on the GPIB bus, the response drops to glacial speeds.

Details:
Mac OS X, LabVIEW 8.20 (but seen with other version)
PCI-GPIB -> NI GPIB Isolator model 120 -> GPIB Instruments
VISA version 4.0

LabVIEW ChampionLabVIEW Channel Wires

0 Kudos
Message 1 of 6
(3,985 Views)
Hi Scott,

We were able to replicate your issue here, and found that when using the NI-VISA API the serial poll timeout was not being modified. The serial poll timeout determines how long the GPIB controller will wait for a response from an instrument before aborting the serial poll.

I have reported the issue to the VISA Team for evaluation.

Thanks,

Jason S.
GPIB Software
National Instruments
Message 2 of 6
(3,931 Views)
Thanks! Can you post a CAR # here. It actually gets automatically (manually) tracked that way.

Thanks,
Scott

LabVIEW ChampionLabVIEW Channel Wires

0 Kudos
Message 3 of 6
(3,929 Views)
Hi Scott,
This was reported to R&D (# 458GNH7K) for further investigation. A possible workaround is to set the timeout using GPIB (NI-488.2) functions instead. The equivalent VI for setting the timeout value would be SetTimeOut.vi and sets both timeout values. ReadStatus.vi reads the status byte. I hope this helps!
 
Thanks for the feedback!
 
Regards,
Missy S.
Project Engineer
RoviSys
0 Kudos
Message 4 of 6
(3,906 Views)
Missy,

Thanks for the workaround!! That is a big help, and I will try it.

In general I have found that mixing traditional GPIB and VISA calls leads to system lockup, instability etc. I have never tracked it down clearly enough to report it, but it always ended up as the following

"Doctor, it hurts when I do this."

"Don't do that"

If I can ever get a repeatable example I will try to report it.

-Scott

LabVIEW ChampionLabVIEW Channel Wires

0 Kudos
Message 5 of 6
(3,901 Views)
Hi Scott,
 
I normally do not encourage the mixing of VISA and GPIB calls either, and do not believe that mixing the calls would work in this situation.  I would recommend that you use the GPIB calls to perform your instrument scan, and then you can open a VISA session and use that for the duration of your application.
 
-Jason S.
0 Kudos
Message 6 of 6
(3,891 Views)