10-17-2006 07:52 AM
10-18-2006 11:04 AM
Hi Moni,
This is expected behavior with the TDM storage file. All of the data is stored in RAM until the file is closed (see Can I Use the Storage VIs in LabVIEW 7.1 to Stream to Disk? for details).
To get around this you can either write to a binary file (not TDM), or use a TDMS file which was introduced in LabVIEW 8.2. The above document discusses using a TDM Header Writer to have TDM functionality when writing to a basic binary file if you do not have LabVIEW 8.2.
Hope this helps,
Jennifer O.
Applications Engineer
National Instruments
10-21-2006 06:19 AM
10-23-2006 03:39 PM
Hi Monika,
Yes it is possible to acquire data without filling your RAM by using a simple binary file instead of TDM. This way you read a smaller amount of data, write it to file, and then acquire more data.
See your LabVIEW examples (Help>>Find Examples) for 'Write Binary File.vi'. This example shows a single write to a binary file. The data is simulated. This example can be easily adapted to your application by replacing the simulated data with your data read function(s) and placing a while loop around the acquisition and file write portion of the code to make the operation repeat. Leave the open and close functions outside of the while loop so that the execution is as follows:
1. Open file& set up acquisition task
2. Acquire data & write to file (repeat until stop condition is true)
3. Close file and stop/clear acquisition task
Regards,
Jennifer O.