LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

LabVIEW TCP/IP Client and Server, I need to send commands and receive feedback on the server side from the client, regarding the command sent.

Solved!
Go to solution

Hi all,

 

I can setup my two PCs, one as a client and one as server very well. I am able to send commands from the server to the client. However, I'm trying to determine how I can get feedback from the client to the server that something has changed, or an ACQ that the command was received. How can I do this in LabVIEW with the TCP/IP toolbox, or is there a better way to do this? 

 

Thanks for your help!

 

Best regards,

 

-Gmac

0 Kudos
Message 1 of 5
(3,981 Views)
Solution
Accepted by topic author gmacca01

Once the connection is established, TCP doesn't care which end is the "server" and which is the "client". Data can be sent in both directions using the same Read and Write functions. So, if you're already able to send data from the client and read it on the server, you should be able to do the same to send data from the server to the client, using the same TCP connection.

 

If that's not clear, please post your code so we can provide more specific advice.

0 Kudos
Message 2 of 5
(3,976 Views)

Technically "ACK" is built into TCP communication as opposed to UDP.   If an ACK is not received then the TCP stack will send the packet again.  If the packet is corrupted then the checksum will not match and the packet is discarded and a retransmit is requested.

 

TCP is fairly robust communication and you will see the connection status drop out if a packet is not acknowledged.  You can add your own handshaking on top if you want more than just an ACK signal.  Other than that, just what Nathan said.

LabVIEW ChampionLabVIEW Channel Wires

0 Kudos
Message 3 of 5
(3,960 Views)

Thanks nathand, you are correct, as long as the connection is setup, i can read and write from both sides. Thanks!

0 Kudos
Message 4 of 5
(3,945 Views)

Thanks STH, yes, nathand is right. 

0 Kudos
Message 5 of 5
(3,943 Views)