LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

tcp reference is lost

Solved!
Go to solution

@ssnp wrote:

it was a wrong wiring.

thanks for help to all of you

  One question is still in my mind how long I can expect  the TCP connection is valid. It is till the TCP  reference is close and can use same connection in my other vi. If yes then how


Ben's famous Action Engine Nugget is always a good read

 

You are completely missing the greatest feature of an action engine.  It provides a SINGLE point where ALL actions on a given resource must go through.  You really want to avoid attempting to access that TCP connection without going through the action engine.


"Should be" isn't "Is" -Jay
0 Kudos
Message 11 of 13
(778 Views)

Jeff is correct.  Any communications through this port should go through this Action Engine/library.

 

But one thing to be aware of with TCP/IP.  Windows likes to auto close ports that are not being used.  So you will need to make sure you are constantly sending and receiving data.  By constantly, I mean do a ping message every 30 seconds or so.


GCentral
There are only two ways to tell somebody thanks: Kudos and Marked Solutions
Unofficial Forum Rules and Guidelines
"Not that we are sufficient in ourselves to claim anything as coming from us, but our sufficiency is from God" - 2 Corinthians 3:5
0 Kudos
Message 12 of 13
(774 Views)

It is not just Windows that will auto close ports. RFC793 specifies a per device "user timeout" that causes all devices to close a port.

 

"USER TIMEOUT

    For any state if the user timeout expires, flush all queues, signal
    the user "error:  connection aborted due to user timeout" in general
    and for any outstanding calls, delete the TCB, enter the CLOSED
    state and return."

 

A proposed change is in the works; TCP User Timeout Option (RFC5482) that would help the situation but it has not been approved.

 

Kind regards,

 

Rick

0 Kudos
Message 13 of 13
(750 Views)