LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Slow response on program...

Check this out, any response is welcome. It seems that the update speed is so slow, as well is that the text file gets updated only every couple of seconds. Also error -10401 is genreated all the time.
0 Kudos
Message 1 of 4
(3,052 Views)
The code is slow because you are using the "High Level" VI's to do your I/O.

Explore the examples that show continuous acquisition to see how to start up the I/O outside your main loop, and then do repeated reads inside the loop.

The -10401 is another issue. Issolate the offending code and let us know what is failing.

Ben
Retired Senior Automation Systems Architect with Data Science Automation LabVIEW Champion Knight of NI and Prepper LinkedIn Profile YouTube Channel
0 Kudos
Message 2 of 4
(3,052 Views)
Ben is right. These top-level VIs are so high-level that they will commonly slow down an application which uses them often. Each time you use one, it must open up a new reference, access it, and then close it again. On the other hands, if you use the Advanced VIs, you only open a reference once and close it once. This is much more efficient.

The error you are getting is a different problem altogether. Here is the meaning of the error:

The specified device is not a National Instruments product, the driver does not support the device (for example, the driver was released before the device was supported), or the device has not been configured using the Measurement & Automation Explorer.

Does this error get generated while your code is running? You may be se
nding the wrong device number or something similar to cause this. Let us know what you find.
J.R. Allen
0 Kudos
Message 3 of 4
(3,052 Views)
It definatly helpped switch the vi. Attached is the new program, it seems to update faster and writes to file about ever 0.6 seconds. Although I would like this down to 0.3s. This may do, being that I am know reading two frequencys, which seem to slow the process down alot. See what you think. There also seems to be a buffer over run (I think) on the graph.
0 Kudos
Message 4 of 4
(3,052 Views)