NI TestStand

cancel
Showing results for 
Search instead for 
Did you mean: 

Large file size for continuous monitor DAQ 6052E

I am trying to use continuous monitor to acquire data from my two 6052E DAQ cards. I am using traditional daq vi's. The DAQ cards are running simultaneously in a seperate thread in TestStand while the rest of my test is running. The tests get lengthy (20 min) and the file size of the data files also becomes large (there are 32 channels monitored on one card and 4 on the other each monitored at a sample rate of 10k). I have set the write to file in a while loop, but because of the large file size I have stripped off important signals and written them to their own (smaller) file. Problem is, now my system is getting bogged down bc the write to file and data recording is taking a while. My scan backlog continues to get large
r and the tests in teststand begin to fail (I think this is bc the DMM driver is not getting enough processor time to finish it's operations). How should I deal with monitoring so much data and keeping the file size down? This is obviously not the best way.
0 Kudos
Message 1 of 2
(2,819 Views)
File I/O is usually one of the slowest operations on a computer. Make sure that you are not opening and closing the file inside of the while loop. It sounds like you are using the Write Characters to File VI, which is a high-level VI that opens and closes the file automatically.

A more efficient way of doing this is to open the file outside of the loop using the Open File VI, use the Write File VI inside of the loop, and Close File outside of the loop. Also, a binary file will be more efficient than writing an ASCII file. Writing a file still takes time, but it will be greatly more efficient doing it this way.

Allen P.
National Instruments
0 Kudos
Message 2 of 2
(2,818 Views)