07-26-2021 12:18 AM - edited 07-26-2021 12:20 AM
Hi all,
We are trying to parse processed data from a Labview application in one computer to another. We are trying to connect via TCP blocks ,but we only have information about the IP addresses of the two systems. We are unable to understand how to find the remote port or service number and also please let us know if there is any other effective way to send processed data between VIs on different computers.
VI blocks :TCP Open Connection, TCP Read, TCP Write.
07-26-2021 01:48 AM
Hi anir,
@anir24 wrote:
We are trying to connect via TCP blocks ,but we only have information about the IP addresses of the two systems. We are unable to understand how to find the remote port or service number and also please let us know if there is any other effective way to send processed data between VIs on different computers.
VI blocks :TCP Open Connection, TCP Read, TCP Write.
You can/should define the port for your communication channel…
Have you tried to use NetworkStreams instead of plain TCP/IP? LabVIEW comes with ahuge example library and also has examples for using NetworkStreams…
07-26-2021 07:23 AM
@anir24 wrote:
VI blocks :TCP Open Connection, TCP Read, TCP Write.
The server should use TCP Listen.vi instead of TCP Open Connection. You then get to define the port used for the connection.
07-26-2021 07:29 AM
You should also define what you mean by "parsing processed data". Do you expect to download a file and work on it locally?
07-26-2021 07:37 AM
The processed data is of data type string and it contains data regarding status of process. This data is used only for monitoring a process from a remote computer.
07-26-2021 09:47 AM
@anir24 wrote:
The processed data is of data type string and it contains data regarding status of process. This data is used only for monitoring a process from a remote computer.
Oh, okay. So if you haven't already, you will have to design a communications protocol to define data start, data stop, and (optional) is what you got what you sent?
07-26-2021 10:26 AM
@crossrulz wrote:
@anir24 wrote:
VI blocks :TCP Open Connection, TCP Read, TCP Write.
The server should use TCP Listen.vi instead of TCP Open Connection. You then get to define the port used for the connection.
For the basics which VIs you need have a look at the example "Simple TCP.lvproj" from the NI Example Finder, too.
Regards, Jens