LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Slow Network

Solved!
Go to solution

Just a general question...

 

At times, I've noticed that our file server on our company's netowrk is extremely slow at times. How do you guys go about programming for slow network speeds on your internal network and occasional use over the WAN?

0 Kudos
Message 1 of 5
(2,629 Views)

You need to be a bit more specfic. How is the network latency affecting you? If you are having issues writing to file impacting your data collection or processing then it is generally advised to separate your file I/O task from the data collection. Do each in a separate loop and pass the data via a queue, notifier or user event.



Mark Yedinak
Certified LabVIEW Architect
LabVIEW Champion

"Does anyone know where the love of God goes when the waves turn the minutes to hours?"
Wreck of the Edmund Fitzgerald - Gordon Lightfoot
0 Kudos
Message 2 of 5
(2,613 Views)

I will be writing data to a comma delimited text file that the user specifies via a Express File Dialog. As a workaround, the file is saved to a location on the hard drive (usually the desktop), data written there, then exported to the file server when the user is done with their testing.

 

The latency is causing slow saves on the network when pointed to save there, which gobbles up time the user could be doing some other action instead of waiting for the program to respond.

0 Kudos
Message 3 of 5
(2,605 Views)
Solution
Accepted by topic author Eric1977

First, the express VIs are generally very inefficient. I would use the file primatives directly. Secondly, it sounds like you are writing to the file in the same task (part of your code) that you are doing your other work. As I mentioned above you should separate the file processing into it's own task. In LabVIEW this will be a parallel loop to the main loop. Pass the data to be logged to the logging task via a queue. You can find examples for how to work with files and how to use queues in the shipping examples. You may also want to look at the examples for the producer/consumer architecture. What I am proposing is essentially a producer/consumer construct. It would also be helpful in the future if you include the code you are having difficulty with. It is much easier to give advice when we can comment directly on your code rather than just giving you generic answers.



Mark Yedinak
Certified LabVIEW Architect
LabVIEW Champion

"Does anyone know where the love of God goes when the waves turn the minutes to hours?"
Wreck of the Edmund Fitzgerald - Gordon Lightfoot
0 Kudos
Message 4 of 5
(2,602 Views)

Actually, generic answeres was what I was looking for. Your answers appear to have helped me out. Thanks!

0 Kudos
Message 5 of 5
(2,584 Views)