LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Communication between two PCs

Solved!
Go to solution

I'm trying to read a .log file on computer A from computer B using LabVIEW. Computer A writes to a .log file when an event begins, and I would like to trigger my data acquisition device that's connected to computer B once that log file has been written to. 

 

Computer A

  • Does not have LabVIEW installed and is not connected to the internet; preferably would like to keep it that way if possible
  • Writes to a .log file after a certain event has started
  • Windows 7

Computer B

  • Has LabVIEW 2024
  • Connected to my DAQ that I would like to trigger after the log file has been written to (the lower the latency the better)
  • Windows 11

 

Both computers have ethernet ports. 

 

One alternative would be to have computer A communicate to computer B when it wrote to the log file; computer B doesn't necessarily have to be the one checking the log file, it just needs to know when it was changed.

 

Based on this post Using the Right Networking Protocol it would seem that Network Streams or TCP would best fit this application, but I'm unsure how to begin executing it without LabVIEW on computer A. Any feedback is much appreciated. If you need more information about computer A or B, please let me know.

 

 

 

0 Kudos
Message 1 of 4
(232 Views)
Solution
Accepted by topic author concretemuncher

Hi muncher,

 


@concretemuncher wrote:

I'm trying to read a .log file on computer A from computer B using LabVIEW. Computer A writes to a .log file when an event begins, and I would like to trigger my data acquisition device that's connected to computer B once that log file has been written to. 

 

Computer A

  • Does not have LabVIEW installed and is not connected to the internet; preferably would like to keep it that way if possible
  • Writes to a .log file after a certain event has started
  • Windows 7

Computer B

  • Has LabVIEW 2024
  • Connected to my DAQ that I would like to trigger after the log file has been written to (the lower the latency the better)
  • Windows 11

 

Both computers have ethernet ports. 

 

One alternative would be to have computer A communicate to computer B when it wrote to the log file; computer B doesn't necessarily have to be the one checking the log file, it just needs to know when it was changed.


When computer B needs to read a file located on computer A then it needs access to its harddrive:

  • you need to connect both computers using some network communication
  • you need to allow access to computer A for computer B

Ask your IT department on how to implement this.

 

Then write a simple LabVIEW routine that checks to folder on computer A for that log file…

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
Message 2 of 4
(153 Views)

GerdW,

 

Unfortunately I figured it might have to come that but wanted to check with the community. Thank you for your feedback!

0 Kudos
Message 3 of 4
(82 Views)

If you cannot share folders between the two computers, you might consider using a messaging protocol such as zeromq.  It is ported to many languages and hides all of the networking details.  It is a useful method of transferring data among programs written in different languages.  I tried a test using it in Python, and was able to read the messages in other programs running on multiple computers in both LabVIEW and Python concurrently.

0 Kudos
Message 4 of 4
(46 Views)