Instrument Control (GPIB, Serial, VISA, IVI)

cancel
Showing results for 
Search instead for 
Did you mean: 

viRead() returning VI_SUCCESS_TERM_CHAR

We have a system talking to various instruments using VISA. Some instruments are GPIB, which we access via a GPIB-ENET/100 converter. We recently a new system, and the code on that is seeing reading data from the instrument, but is returning a status of VI_SUCCESS_TERM_CHAR instead of VI_SUCCESS. I worked around it for now, but I'd like to figure out why this is happening on this station, and not on the original. Could it be a configuration problem of some sort? 

 

 

 

Brian

 

0 Kudos
Message 1 of 4
(4,322 Views)

I have not seen the warning code VI_SUCCESS_TERM_CHAR, but it apparently means the VISA read function has terminated with encountering the termination char specified by VI_ATTR_TERMCHAR attribute (normally set to 0x0A as default) under the condtion that VI_ATTR_TERMCHAR_EN attribute TRUE.

 

Normally a GPIB instrument, when responding, terminates with 0x0A code and EOI signal set at a time. But some old instrument may not set EOI signal at the final character. In this case, the only condition to terminate is the termination character and VISA may issue that warning code when encountering the character code without detecting the EOI signal.

 

Anyway, that warning code is not an error (because the value is not negative) so your app can simply ignore the code, as long as the response string was correctly read.

 

Makoto

0 Kudos
Message 2 of 4
(4,311 Views)

The same instrument works fine in the software development system. The only difference that I can determine at this point is that the development system is using an older version of VISA.

 

We can't ignore the condition, as we are developing deliverable code. I have to determine why this is happening.

 

 

 

Brian

 

0 Kudos
Message 3 of 4
(4,309 Views)

I am working on a system that has both VXI and GPIB instruments.  I changed the VXI resource manager from an NI slot 0 to a Bustec slot 0 and uninstalled NI-VISA and installed Bustec VISA.  After making these changes, I started getting the VI_SUCCESS_TERM_CHAR warning when doing a viRead on a GPIB instrument.  I suspect that Bustec VISA is causing the issue and not the GPIB instrument.  Did you ever resolve your issue?  I would be interested in your solution to see if it might apply to my situation.  Thanks.

0 Kudos
Message 4 of 4
(4,077 Views)