LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

remote client vi drops tcp/ip connection

I have a simple client VI that calls a master VI on a server to get/set a couple of controlls.  The client VI will drop the tcp/ip connection after 30 sec, giving an LabView error 60.  It stays out for about 90 sec, and comes back again for 30 sec. and the whole process repeats.   The VI Server is configured to use port 3363.   If I change it to some other number, the client VI will give error code 56.  Could someone give me some insights of what maybe going on?  Thanks very much.
0 Kudos
Message 1 of 10
(4,043 Views)
djcamom,

That certainly sounds like odd behavior.  Can you run the TCP Server/Client Examples in the Example Finder and see this same behavior?  Do you have any communication problems between these two computers?  If you see the same behavior with the examples then the behavior could be related to the network connection.  If not, then it could be your code.  It would be helpful if you can simplify your code and post that I would be glad to take a look at it. 

Thanks!
Andy F.
-----------------------------------------------------------------
National Instruments
Message 2 of 10
(4,031 Views)

I am facing same problem. When I run TCP server I get Error 60. I have checked the firewall settings also.  Also I have tried the tcp reconnect vi , it's not opening in LV 8.5. Kindly help.

yashpal.

 

0 Kudos
Message 3 of 10
(3,866 Views)
Hello Yashpal, 

Could you tell us exactly the name of the VI that you are using?  Also, can you tell at which exact function the error is occuring?  With this information we will be able to better help you.  You can even try posting a screenshot of the error.

Thanks!
Kameralina

0 Kudos
Message 4 of 10
(3,843 Views)

dear FieldKam,

 

The error occurs at TCP open connection function. The VI that I have mentioned reconnect.vi  , was posted on forum by one of ni application engineer as a solution of the above problem. Error message that appears is error 60, port already in use.

 

thanks,

yashpal.

0 Kudos
Message 5 of 10
(3,827 Views)

The port you selected may be used by something else.
Set up your port only for this communication and disable everything else which is trying to read/write to this port.

RayR

0 Kudos
Message 6 of 10
(3,822 Views)

The port you selected may be used by something else.
Set up your port only for this communication and disable everything else which is trying to read/write to this port.

RayR

0 Kudos
Message 7 of 10
(3,822 Views)

How do I disable everything else on a port?  If for example I am using Port 28000 how would I determine if there is something else using this port?  How do I ensure only my app is using this port?

 

Thanks

 

Dan

Dan Shangraw, P.E.


   

0 Kudos
Message 8 of 10
(3,614 Views)

ASTDan wrote:

How do I disable everything else on a port?  If for example I am using Port 28000 how would I determine if there is something else using this port?  How do I ensure only my app is using this port?

 

Thanks

 

Dan


The only way to reserve your port for sure is by acquiring it as early as possible. Once grabbed you own it and can use it until you release it.

 

Rolf Kalbermatter

Rolf Kalbermatter  My Blog
DEMO, Electronic and Mechanical Support department, room 36.LB00.390
0 Kudos
Message 9 of 10
(3,604 Views)

rolfk wrote:

ASTDan wrote:

How do I disable everything else on a port?  If for example I am using Port 28000 how would I determine if there is something else using this port?  How do I ensure only my app is using this port?

 

Thanks

 

Dan


The only way to reserve your port for sure is by acquiring it as early as possible. Once grabbed you own it and can use it until you release it.

 

Rolf Kalbermatter


At least if you are using a recent LabVIEW version, you can rather use a dynamic IP Port and register that port in your ServiceLocater service. The Open TCP Connection node supports connecting a string to its port input that identifies a specific service that has been registered with the Service Locater service on the remote machine.

 

The TCP Create Listener node allows to specify a string as service name, with which the port will be registered in the local Service Locator. So you can loop through the ports until you find one that opens without problems and that port will be registered in the local Service Locator under the name you specify.

 

This only works without problem when the client and server are both in LabVIEW, but the NI Service Locator protocol is fairly trivial and could be added to other clients easily too. To query for instance for a specific serivce name you simply send the string "GET /<service name> HTTP/1.0\r\n" to the port 3580 of the IP address you want to query a service for.

 

Rolf Kalbermatter

Message Edited by rolfk on 09-10-2009 11:18 AM
Rolf Kalbermatter  My Blog
DEMO, Electronic and Mechanical Support department, room 36.LB00.390
Message 10 of 10
(3,590 Views)