11-12-2010 10:05 AM
Hi,
I have a customer with a prototype device that uses a NI USB to RS-422 interface connected to a PC. On the LabVIEW application, the following error code from the serial port is seen: -1073807252
What does this code mean? Is there a place where the serial port error codes are discussed?
Thanks.
Bob
Solved! Go to Solution.
11-12-2010 10:12 AM - edited 11-12-2010 10:12 AM
Right-click on the error cluster and select "Explain error".
Or, use the Simple (or General) Error Handler.
It tells you: VISA: (Hex 0xBFFF006C) An overrun error occurred during transfer. A character was not read from the hardware before the next character arrived.
It basically means you're not reading the stuff from the serial port fast enough.
11-12-2010 10:57 AM
Thanks for the insight!
03-03-2011 01:31 PM
hallo Robert_Deschambault!
I have the same problem with VISA. Before I used an USB-SERIAL adaptator with my notebook and I thought the adaptor was the problem but now I work with a normal computer (without adaptor) and comes the same error menssage...
I'm crazy looking in forums for a solution but so far I haven't found nothing!
Can you say me if you've solved your problem?
Thank you!
03-04-2011 07:05 AM
Hi, yes I was able to solve my problem. Initially I did not have RTS/CTS flow control implemented and once we set that up these errors went away. Let me know if this is an issue.
I also had issues with having serial messages coming from several different LabVIEW sub-vi's and the "collisions" led to scrambled messages. Once I enforced that no messages would be sent simultaneously, that problem went away. I also used semaphores to protect against this as well.
Finally another issue is that I had to calculate the delay to allow the characters to be sent. When I had long messages, I had to make sure there was enough time to get the message out before the next was to be sent out.
03-04-2011 12:22 PM
Hello Robert,
Thanks for your reply.
I'm working with the serial communication without flow control, then I don't have a TermChar or a order from my device to transfer. Also, I run my Labview program and I transfer and receive continually strings all time. My strings of the communication have only header bytes.
Do you have any idea for the same problem but with those conditions of the problem?
Or can you send me a screenshot of your VI to probe with your settings?
Thanks.
03-04-2011 12:48 PM
In my case, the problem that generated the error was the flow control one. The other errors were more subtle and only understood after some analysis with a logic analyzer.
03-04-2011 01:03 PM
yes, but how have you solved the problem with the flow control? only for software from labview?
or did you have to modify your string from your device and than you could receive a bit to control your flow of data?
for example a TermChar...
03-04-2011 01:05 PM
@Deutschrich wrote:
yes, but how have you solved the problem with the flow control? only for software from labview?
or did you have to modify your string from your device and than you could receive a bit to control your flow of data?
for example a TermChar...
You should take a look at the "Bytes at Port" function in Instrument I/O >> Serial
Using this, you can determine how much data there is to read, take care of that, then worry about parsing these strings later on.
First things first, you want to get the data out of the port and into memory.
But yes, a termination character will help with the parsing of the string.
03-04-2011 01:12 PM
Oh, sorry ... what we had to do was to connect the RTS/CTS flow control lines properly and then enable hardware flow control from the VISA configure serial port. I have attached my code as an example. I also had to configure the port to handle the end character, in my case there wasn't any.