LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Flushing TCP/IP in Labview. Low level TCP/IP in labview.

I'm using TCP/IP communication in Labview 7.0 in Linux. My program keep on sending request for connection to a Network server for the long period even if the server is down. I'm getting buffer space not available error after a period of time and all network services are down. I suspect that it is caused by my VI pumping requests to the server. So, I would like to try to flush out the TCP/IP buffers in Labview program. How can I do that. In Winsock, we can call flush(). Correct? How can we do the same thing in labview.
0 Kudos
Message 1 of 6
(7,809 Views)
Hello Mr,

Unfortunately, there is not �flush TCP buffer� function in LabVIEW. However, the TCP functions should not be sending information or filling the buffer without receiving an ACK (acknowledge) from the server. This is how TCP is implemented. If the server is down when the initial connection is attempted, you could try setting the timeout on the connect to fewer seconds (I think the default it 60).

If none of these suggestions help, or if I�m not correctly understanding your issue, please reply with comments or answers to the discussion above and any additional information that may help, and I�ll be happy to look further into it.

Have a nice day!

Robert Mortensen
Applications Engineer
National Instruments
Robert Mortensen
Software Engineer
National Instruments
0 Kudos
Message 2 of 6
(7,807 Views)
Hi Robert,


So, I should reset the timeout at tcpConnect to lower value? my ReadBuffer timeout is 8 second because of delays in server.

How will it help by lowering the timeout value at LabView? And will it matter whether the connection is closed through handshaking or timeout due to abrupt change in server condition?
0 Kudos
Message 3 of 6
(7,807 Views)
Hi,

Another Question on TCP. Can I turn off Nagel algorithm in Labview socket implementation?
0 Kudos
Message 4 of 6
(7,807 Views)
Hello Mr,

The timeout used on TCP Connect will only affect the application when it is connecting to the server. It will have no effect after the connection has been established. Where are you setting the ReadBuffer timeout to 8 seconds? How are you seeing that your buffer is being filled? What timeout do you have on your TCP Write?

LabVIEW TCP functionality is fairly high-leveled. That is, you cannot control lower level functionality, such as the Nagel algorithm.

There is a great utility for seeing exactly what is put out on the network. It is called Ethereal. It is a free third-party application you can download on the web. It will allow you to see exactly what packets are being sent by LabVIEW to your server, and if they are bei
ng acknowledged by the server.

Have a nice day!

Robert Mortensen
Applications Engineer
National Instruments
Robert Mortensen
Software Engineer
National Instruments
0 Kudos
Message 5 of 6
(7,809 Views)
See this link for shutting off the Negel algorithm.

http://digital.ni.com/public.nsf/websearch/7EFCA5D83B59DFDC86256D60007F5839?OpenDocument

Ben
Retired Senior Automation Systems Architect with Data Science Automation LabVIEW Champion Knight of NI and Prepper LinkedIn Profile YouTube Channel
Message 6 of 6
(7,804 Views)