From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

TCP/IP network address is ill-legal means

Hi,
 
I want to make a server client network using TCP/IP. I have 3 PC connected.  one is server and other 2 are clients. so, i have assign 2060 as a port no to server , 2055  to 1 client and other 2056 to 2nd client.I was able to make the connection. server and client both can read and write the data to each other. But sometimes there is a data lost. ( that means data is getting trasferred from the server without error, but the client is not getting the respective data). So, to resolve this problem i conneted the IP address of client in the 'Wait for listener' VI  with the respective clients port no in the server write loop. When i run this VI i got an error message " Network address is ill-legal". Please suggest some solution to resole this error. Also i want to know that why is error occured? 
I am using LV 7.1


Message Edited by Ranjeeta on 05-23-2008 03:54 AM
0 Kudos
Message 1 of 5
(2,958 Views)
If you add the netaddress to the wait for listener it has to be the IP address of the server. This can be used to select between multiple network cards. If you only have 1 with only one address set, you don't have to connect it. The illformed message address error is set because the IP address entered is not one of the server.




Message Edited by andre.buurman@carya on 05-23-2008 12:39 PM
Regards,
André (CLA, CLED)
0 Kudos
Message 2 of 5
(2,944 Views)
In TCP listen VI, what IP address should i connent when server is writting to the multiple client?


Message Edited by Ranjeeta on 05-23-2008 06:26 AM

Message Edited by Ranjeeta on 05-23-2008 06:28 AM
0 Kudos
Message 3 of 5
(2,935 Views)
None, this makes the server listen to all networks for the given port. Whenever a client tries to make a connection you need to keep the connection reference the listener give alive and parallel to that you should start listening again for the next client to connect. Etc.

When LV receives a connection attempt it redirects the traffic to another port a give you a reference. It that way the port that the client connects to stays free for new connections. Like a webserver, which listens on port 80.

The TCP-IP server/ multiple client examples show this.
Regards,
André (CLA, CLED)
0 Kudos
Message 4 of 5
(2,928 Views)


andre.buurman@carya wrote:
None, this makes the server listen to all networks for the given port. Whenever a client tries to make a connection you need to keep the connection reference the listener give alive and parallel to that you should start listening again for the next client to connect. Etc.

When LV receives a connection attempt it redirects the traffic to another port a give you a reference. It that way the port that the client connects to stays free for new connections. Like a webserver, which listens on port 80.

The TCP-IP server/ multiple client examples show this.


Actually TCP Listen does not redirect a connection to another port at all. The TCP protocol allows multiple connections to the same port on a machine as long as the remote address and /or port are different.

Rolf Kalbermatter
Rolf Kalbermatter
My Blog
Message 5 of 5
(2,884 Views)