IO timeout

270 views
Skip to first unread message

Student

unread,
Mar 4, 2017, 10:11:05 AM3/4/17
to python-ivi
Hi People!

I'm trying to:

import vxi11
instr = vxi11.Instrument("192.168.0.26")
print(instr.ask("*IDN?"))
...
instr.ask("DATA:LOG:STATe 1")
...

Which results in:
HAMEG,HMC8012...
...
Traceback (most recent call last):
  File "multiple_measurements.py", line 14, in <module>
    instr.ask("DATA:LOG:STATe 1")
  File "build/bdist.linux-x86_64/egg/vxi11/vxi11.py", line 743, in ask
  File "build/bdist.linux-x86_64/egg/vxi11/vxi11.py", line 731, in read
  File "build/bdist.linux-x86_64/egg/vxi11/vxi11.py", line 701, in read_raw
vxi11.vxi11.Vxi11Exception: 15: IO timeout [read]
...

But nonetheless starts the logging alright - is there a way around handling the exception? Like configuring the IO timeout, or even better maybe not even wait for the read (like just sending, not waiting for something coming back)?

Best, Student

Alex Forencich

unread,
Mar 4, 2017, 1:08:52 PM3/4/17
to pytho...@googlegroups.com

Instead of

instr.ask("DATA:LOG:STATe 1")

try

instr.write("DATA:LOG:STATe 1")


Alex Forencich

--
You received this message because you are subscribed to the Google Groups "python-ivi" group.
To unsubscribe from this group and stop receiving emails from it, send an email to python-ivi+...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

signature.asc

Student

unread,
Mar 6, 2017, 5:50:32 AM3/6/17
to python-ivi
Thank you very much, thats exactly what I was looking for! Sorry for asking such a possibly extremely obvious question - is there a good place on the internet for example scripts? (Maybe I could contribute the basic scripts I wrote so far if there is nothing as of jet)
Reply all
Reply to author
Forward
0 new messages