LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How can the TCP Read buffer be cleared or data flushed?

 
0 Kudos
Message 1 of 5
(4,621 Views)
Try using TCP Read with a large number of bytes to read and a small timeout.

___________________
Try to take over the world!
Message 2 of 5
(4,613 Views)
Thanks for your suggestion, I have thought about that, but was hoping for some property/function similar to the Serial RX/TX flush. I had thought that there would be one but have been unable to locate such a mechanism.
0 Kudos
Message 3 of 5
(4,609 Views)
There is no specific method for flushing the buffer in LabVIEW. However, you can get this behavior by doing a TCP read with the Mode set to immediate. This will return all data currently available (which could then be ignored) and clear out the read buffer.

Regards,

Matt F
Message 4 of 5
(4,597 Views)
Thanks for the additional info. Since the app is time sensitive, I am experimenting with TCP read with controlled timeout. Thanks all again for the suggestions.

Cheers,
Don
Rochester, NY
0 Kudos
Message 5 of 5
(4,593 Views)