04-11-2011 03:06 PM
Hi,
Take your time. I have enough troubles of my own ![]()
In your VI 'Receive_Data.vi' you are still get the number of bytes and read these bytes from the serial port. This is possible but you have to take into account that this can be zero.
I think it is better to wait for a specified time to see if there are the expected number of bytes available at the port.
But there are more solutions thinkable. You can look in the timeout event (don't set it to zero) if there are bytes available.
If the number of bytes is not zero and the same as the previous check then create a event to get data.
See if you work this out.
Kees
04-15-2011 07:11 AM
It's working !! I remodifed the read sub VI and it's working great now ! thanks alot for the help, I attached the file again to show you what I changed.
04-16-2011 03:15 PM
It's great that is working and even better you did it yourself. Best way to learn.
One remark to make it better; within the case 0 you could generate a failure to indicate a time-out on your interface. But it also depends on your application.
Kees