Instrument Control (GPIB, Serial, VISA, IVI)

cancel
Showing results for 
Search instead for 
Did you mean: 

PM6000 VISA timeout

Solved!
Go to solution

Hello,

 

   I'm trying to control a Voltech PM6000 over LAN with LabVIEW. So far so good, I can communicate with the instrument after adding it in MAX as a TCPIP resource (RAW with port 36003). However, if I request more bytes by VISA READ than are available in the buffer, the VISA comms wait for a timeout and I get the error -1073807339. The other instruments I'm communicating with via VISA over LAN just return the characters in the buffer (i.e. request for 100 bytes may return 60 but immediately without the timeout). Is there any way of getting all of the data from the PM6000 buffer without getting this error, if you don't know how much data there is in the buffer to start with?

 

   Cheers,

 

    Tim

0 Kudos
Message 1 of 5
(4,219 Views)
Solution
Accepted by topic author Tim_Butler

A visa read stops at the end of a message when it detects the end of the message.

In gpib this is either an end character or EOS ( a hardware line)

In LAN it only can be an endcharacter and that should be defined.

 

Check this carefully

greetings from the Netherlands
Message 2 of 5
(4,212 Views)

Thanks Albert,

 

   So I've set the termination character enable in the VISA message-based settings and now there is no timeout error. There's a warning:

 

VISA:  (Hex 0x3FFF0005) The specified termination character was read.

 

But I've no problem in living with that.

 

    Cheers,

 

         Tim

Message 3 of 5
(4,206 Views)

That warning is in fact a mistake in VISA.

If an endcharacter is detected there should be no warning.

Indeed new data could become available but NI should not generate warnings that nobody want to see.

If you read from the serial line a number of characters and you got the characters the same message is given (I believe it is the same I did not  check)

 

So it is best to ignore or even throw away such warning.

greetings from the Netherlands
0 Kudos
Message 4 of 5
(4,196 Views)

Thanks again Albert, I will be clearing that warning.

 

      Cheers,

 

         Tim

0 Kudos
Message 5 of 5
(4,185 Views)