Instrument Control (GPIB, Serial, VISA, IVI)

cancel
Showing results for 
Search instead for 
Did you mean: 

Timeout with visual basic

I was wondering if there was a way to timeout an operation with Visual basic. I am sending and recieving data with NI -488.2 attachment.  I am trying to retrieve data from agilent frequency counter. It works fine if the part is working but if there is no frequency going into the counter the counter will never send back information. So my programs will just sit there. Is there a way to skip out of the function if I do not recieve data with in a certain amout of time.


0 Kudos
Message 1 of 3
(3,011 Views)

My answer to the following thread may give a hint for your issue.  The example code separates the "initiation", "wait for completion", and "data query" blocks for a measurement, though it assumes that the instrument understands SCPI language.

http://forums.ni.com/ni/board/message?board.id=140&message.id=14271

0 Kudos
Message 2 of 3
(3,005 Views)
Thanks. Reading the Status bit idea worked out great.


0 Kudos
Message 3 of 3
(2,993 Views)