LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Communication with two or more computers PC's TCP

Solved!
Go to solution
Highlighted

Hello Everyone...

I come to you with a problem to communicate two computers through TCP using the TCP subvi's, the problem is that both the server and the client vi's(attached) work well on the same computer (using "localhost" as the address) but when I connect two computers though ethernet it just doesn´t work even when I test the connection between the computers making "Ping" with the CMD terminal.

Does anyone have an idea of what is happening?

Thanks from now, I'd appreciate your help.

 

PS: VI's are in Labview 14. Both computers are running on windows 10

Best regards.

Emmanuel.

Download All
0 Kudos
Message 1 of 3
(482 Views)
Highlighted
Solution
Accepted by topic author JEmmanuelH

Your client needs either a service name or a port number in order to connect to the server on the remote PC. In the code you posted there is no service name in the TCP server. It actually doesn't work on my computer without that. Now, there are many other reasons you may not be able to connect even if ping works. One common problem is if you have any firewalls running. That would block the communications. Several ports would need to be open. The NI Name Service Locator port would need to be open on the firewall. That uses port 3580. You would also need to make sure that the port for your server (port 2055 in the code you posted) was open as well. Depending on the network, there could be other firewalls besides the one on your PCs that could block traffic.



Mark Yedinak
Certified LabVIEW Architect
LabVIEW Champion

"Does anyone know where the love of God goes when the waves turn the minutes to hours?"
Wreck of the Edmund Fitzgerald - Gordon Lightfoot
Message 2 of 3
(441 Views)
Highlighted

That was awesome Mark_Yedinak, I just disabled the firewall while running the vi’s and everything worked well. It’s incredible how small details could do a big matter. Thanks a lot.

0 Kudos
Message 3 of 3
(415 Views)