From 04:00 PM CDT – 08:00 PM CDT (09:00 PM UTC – 01:00 AM UTC) Tuesday, April 16, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Serial read LabVIEW: Error overrun

Solved!
Go to solution

I have a serial communication application, I am currently working on. 

 

I have a serial port configured to 115200 baud rate and the data is being sent to the port at every 10 ms. 20 bytes are being sent at a single time, with three state events - HEader, length and Data. You can find it in my attached program (state machine). There is an easy way to implement the VISA close if it is just a while loop, how would one do it in a state machine. Basically when the user presses the stop button or any other button - the serial port should close properly and should not throw any errors, when the program is run again.

0 Kudos
Message 11 of 13
(408 Views)

Hi looser,

 

you still don't have any error handling in your VI.

You still clear the VISA buffer before even configuring the port.

Do you listen to what people are telling you?

 

Typically you close the port after the loop. Try to place that VISAClose function right there…

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 12 of 13
(403 Views)

Mr. GerdW

 

Do you listen to what people are telling you?

 

I listen to what people suggest me and not "tell" me. Unless I work for them. In the last post you suggested few things, I implemented what I think is necessary and working on an other situation. However in the last message of the last post, the way you communicated indicated that you think that I have to listen to whatever you say. I know you think it is the right thing, but it does not matter. I respected your suggestions, made your comment as the answer and moved on to posting on a new post. Again you are taking this personal and commenting on. If you would like to suggest something, pleae do properly. Anyone would appreciate it. Stop taking it personnaly and "telling" me what to do.

 

I understand you know what you are talking about, but that does not give you the right to tell me and comment on my personality. If this happens again, I will report you regardless of your background or your experience.

 

Regards

0 Kudos
Message 13 of 13
(398 Views)