06-30-2016 03:17 PM
I have a power supply connected to my PC over GPIB using VISA. Everything seems to work fine, but when I turn off the power supply, and then try a query, VISA seems to just hang for around 30 seconds. I would expect it to timeout after only a few seconds (or whatever the timeout is set to, which is much less than 30s), but it does not. After this first query, it will timeout in a normal fashion, but the first query after powering off the instrument always takes forever. Nothing else can be sent over GPIB in the mean time. Any idea what might be causing this?
07-01-2016 04:44 PM
Hi roboguy222,
That's definitely very interesting behavior and not something I've personally seen before. What model power supply is it? Do you see the same behavior with other power supplies? Also, how are you performing the query? If you're not already doing this I would try and simplify your code as much as possible, just using VISA test panels in NI MAX with a simple query to see if you still see this behavior.
Thanks,
07-01-2016 06:05 PM
I originally found the problem using pyvisa:
import visa rm = visa.ResourceManager() list = rm.list_resources() ps = rm.open_resource('GPIB0::5::INSTR') ps.query('*IDN?') [TURN PS OFF] ps.query('*IDN?')
The problem was the same, however, if I used the NI Device Monitor to directly query a device. I am using an Agilent 6641A Power Supply, and will check if the problem persists for other instruments soon.
Thanks!
07-06-2016 02:41 PM
Roboguy,
What happens if you leave the power off for a while before querying it? Turn it off, wait 5 minutes or so, then query it. It may be a residual charge or something within the power supply.
10-31-2016 02:37 PM
Updating VISA seems to have fixed this issue.