LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Virtual COM port crashes labVIEW

Solved!
Go to solution
I am using virtual comport for one of my application and sometimes due to time out or lack of processing data my labVIEW hangs and i am not able to stop it properly and the only solution is I un plug the USB cable and which results in a labVIEW crash. Any suggestion to avaiod the crash?
0 Kudos
Message 1 of 8
(3,339 Views)


muks wrote:
due to time out .....


If a time out occurs trere are no data, so it should not crash Labview.
 


muks wrote:
 lack of processing data


What does it mean? Do you have many bytes of data stored at the Visa buffer, without reading them? That could crash Labview.
Just set a bigger buffer, or better, read the data faster.
Message 2 of 8
(3,335 Views)

muks wrote:
due to time out .....

If a time out occurs trere are no data, so it should not crash Labview.

Time out doesnt crash labVIEW.It hangs it .Once i get the time out error i am not able to stop the vi.
0 Kudos
Message 3 of 8
(3,328 Views)



muks wrote:
 lack of processing data

What does it mean? Do you have many bytes of data stored at the Visa buffer, without reading them? That could crash Labview.
Just set a bigger buffer, or better, read the data faster.

I have lot of image processing function which i use after getting the data from the serial port. Once i unplug the cable (Which i shouldnt normally).LabVIEW crashes
Message 4 of 8
(3,327 Views)

If you are processing lots of data through the COM port, you should use a producer consumer loop arrangement in order to read the port consistently.

How are you doing your port read?  What else are you doing (at the same time)?  Are you using an architecture which uses the loop efficiently?  Not just spinning the loop while waiting for data...

Something in the code may be causing LV to crash....

Maybe if you posted your code we could have a look at it. 

R



Message Edited by JoeLabView on 07-29-2008 09:48 AM
Message 5 of 8
(3,318 Views)

How are you doing your port read?  What else are you doing (at the same time)?  Are you using an architecture which uses the loop efficiently?  Not just spinning the loop while waiting for data...


Well i have got  an idea thanx joe will try and let you know
Message 6 of 8
(3,313 Views)
Solution
Accepted by topic author muks
Well sorted the problem and the problem was due to processing junk data and i am performing fft and so it hangs if i dont get a proper data.Nothing to do with lv.Thanx for the replies
Message 7 of 8
(3,283 Views)

Glad you found it.  🙂

I would have been very surprised that something related to serial communication would cause LV to crash.. 😉

R

Message 8 of 8
(3,279 Views)