LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

tcp/ip Server-MultiClient communication

Hi,
I'm trying to develop a multi-client application using TCP/IP communication. I'm trying to do this just like the example in NI example folder i.e., I am constructing a queue of connections and servicing them one by one.
In my application the server responds to the client only when the client requests for data and each client may request for different data at any time. So I have to service all requests parallely.
But in my application the server is sending data to client1 even if the request is coming from other clients. Can anybody help me to solve this problem?
0 Kudos
Message 1 of 4
(3,563 Views)
Hi sow,

I don't know if I fully understand your problem, does the server send all queried data to client1 even when other clients have requested data?
Test Engineer - CTA
0 Kudos
Message 2 of 4
(3,540 Views)
Hi ,

Yes the server gets the number of clients connected to the server. It receives the query sent by all the clients but the data that has to be serviced to the other clients are serviced to the first client that gets connected to the server.

Regards

Sow

0 Kudos
Message 3 of 4
(3,519 Views)
Hi Sow.

Remember that the conversation handle uniquely identifies the client. Are you using the correct handle when you call ServerTCPWrite()?

Regards,
Colin.
0 Kudos
Message 4 of 4
(3,514 Views)