03-31-2009 10:41 AM
04-01-2009 02:08 AM
Hi GMik,
you can read your file in a loop, until EOF? is true.
Mike
04-01-2009 10:34 AM
I was using the "read LVM" express tool. The file was written with the "write LVM" tool. I used the "DAQmx" tool to acquire the data continuously (it defaults to 1KHz, and it also defaults to 100 samples, but I don't think that option means anything when reading continuously).
When reading the file, an option in the tool asks either to "read entire file" or "specify number of samples." If I select "read entire file" it only reads first 100 samples...which I guess is related to it writing 100 samples at a time through the express tool, but I don't know how to turn that off. If I specify a number of samples to read it reads them all...
04-01-2009 11:12 AM
04-01-2009 11:24 AM - edited 04-01-2009 11:26 AM
GMik,
Is there any reason you are doing one header per chunk of samples? I might suggest using one header only in the Express VI to write your file.
04-01-2009 12:23 PM
04-01-2009 12:25 PM
Hmmm,
Could you maybe attach your lvm and possibly a screenshot of your code?
04-01-2009 12:36 PM
04-01-2009 12:54 PM
Hi!
I have come across this problem before. What happens is you use the "Write Measurement File" and input a Waveform datatype (perhaps) and place this in a loop. The one header option seems resonable but you will see in that first header is a line under "Channels" called "Samples" and the value is probably "100". The Read Measurement File function will only read the number of samples specified in the header. So your first measurement hits the Write Measurement File, and creates the appropriate header information for that first measurement. When the second measurement comes along, Write Measruement File only appends to the data (but unfortently does not update the header).
I've written the attached VI "Read LVM to DAQ Cluster (SubVI).vi" which should disect any LVM file (saved in a number of ways w/ different options) and create a cluster with all the data in that LVM file. The "output cluster" has the Waveform Data in the proper format included in it.
Hope this work. This is v8.6 file. Let me know if you want me to convert it to a different LV version (although I'm limited to 8.0+).
-Nic
04-01-2009 12:57 PM