LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

visa read error NNNN

Hello forum,

 

I have been using LabVIEW to acquire data from a Paroscientific pressure transducer using serial port. It has been working well. Right now, after some days of shut down, i restarted the system. Now I get strange string NNNNNA as the visa read out. I checked the serial settings and commands and everything seems to be fine. When I highlight the execution, i dont see any error that is being passed. However, the error cluster indicater at the visa close says, there is a visa read error. If anybody can give me a hint what is going wrong, that is of great help.

 

Thank you,

 

Zacharia 

 

0 Kudos
Message 1 of 15
(3,055 Views)

Can you tell us what the error code is?  Can  you attach a VI.

 

There are numerous things that could be going wrong, and without any details, we can only wildly guess.

0 Kudos
Message 2 of 15
(3,049 Views)

Hi Ravens Fan,

 

The error code is 107367294. From the NI Error directory, I find that this error is returned when more data than I read is available for reading. 

I attach the vi below.

 

Thank you.

zacharia

0 Kudos
Message 3 of 15
(3,043 Views)

That is not an error, just a warning.

 

It says you got exactly the number of bytes you asked for and there is a possibility there are still more bytes in the serial buffer.  And that is to be expected since in your implementation, you asked for how many bytes are in the buffer, than asked to read that many bytes.

 

In my opinion, it is a stupid warning as a programmer's common sense should tell him that there is always a potential for more bytes in the buffer, and if there is a concern, then they should program for that situation.  It makes as much sense as if they put up a sign at every traffic light that warned people that a "red light might appear soon following a yellow light".

 

You can safely ignore this warning.  Are you having any other problems with the operation of your VI?

Message 4 of 15
(3,038 Views)

@Ravens Fan wrote:

That is not an error, just a warning.

 

It says you got exactly the number of bytes you asked for and there is a possibility there are still more bytes in the serial buffer.  And that is to be expected since in your implementation, you asked for how many bytes are in the buffer, than asked to read that many bytes.

 

In my opinion, it is a stupid warning as a programmer's common sense should tell him that there is always a potential for more bytes in the buffer, and if there is a concern, then they should program for that situation.  It makes as much sense as if they put up a sign at every traffic light that warned people that a "red light might appear soon following a yellow light".

 

You can safely ignore this warning.  Are you having any other problems with the operation of your VI?


 

I do have problem with operation of the VI. It reads NNNNN instead of the data.

0 Kudos
Message 5 of 15
(3,033 Views)

That doesn't sound like a LabVIEW problem, but a problem with your instrument.

 

Do you have any other software, like a manufacturer program, to try to read the instrument?  How does that behave?  How about hyperterminal?

 

If LabVIEW is reading NNNN, that is because that is what the serial port is receiving.

0 Kudos
Message 6 of 15
(3,030 Views)

It's your hardware. There's nothing inherent to that VI that would make it read "NNNNN". It works fine on a loopback.

 

Ravens said, regarding the error cluster's warning:

In my opinion, it is a stupid warning as a programmer's common sense should tell him that there is always a potential for more bytes in the buffer.

And for that, I thee Kudo.

Richard






0 Kudos
Message 7 of 15
(3,029 Views)

@broken Arrow wrote:

It's your hardware. There's nothing inherent to that VI that would make it read "NNNNN". It works fine on a loopback.

 

Ravens said, regarding the error cluster's warning:

In my opinion, it is a stupid warning as a programmer's common sense should tell him that there is always a potential for more bytes in the buffer.

And for that, I thee Kudo.


(Sea Story time:---)

Many a year ago we had a test that read back values stored to memory of a HP 3548A Direct Digitzing Multi-meter as RAW adc values.  It took Two guys, Three days and some hair loss to find why we kept loosing samples and getting obviously old data.  Of COURSE we read until term char 0x0A-  How often do you suppose a ADC count of 10 was recorded?  The warning could have put us on the right track but, we suppressed it out of habit.  Maybe HP added this warning for that reasonSmiley Wink

 

(And now, back to your regularly scheduled forum)


"Should be" isn't "Is" -Jay
0 Kudos
Message 8 of 15
(3,022 Views)

Thank you Raven's fan, and others

 

I tried to run this VI on a different computer and it worked. There was an iak file in the computer which uses the same com port. I deleted this file. Right now the vi works, but I am not sure, if it works because i deleted .iak file. However, I found the VI is running slowly. This seemed to me as instrument problem, because the front panel of the instrument is also updated slow.

 

Thank you once again.

 

zacharia

 

0 Kudos
Message 9 of 15
(3,013 Views)

Im trying to use LabView to communicate to the Paroscientific Model 6015A pressure transmitter.  Im using the basic serial write and read structure with a 500 mSec delay in between.  When I send a request for pressure (*0100P3) I dont get a response from the device.  If I use the the Paroscientifc software it works fine.  Any tricks to getting the LabView software to communicate?

0 Kudos
Message 10 of 15
(2,858 Views)