09-16-2016 10:57 AM - edited 09-16-2016 10:57 AM
Hi,
I want to do something dead simple: record a few channels of scalar data during a measurement run that could take many hours. I want to record the data inside the loop so that no data will be lost if something crashes.
I ended up using the "Write to Measurement File" express VI, writing to an LVM file. (Test code is attached.) After much experimentation, I came to the conclusion that I have to set both the "Start Timestamp" as well as the "Timestamp" attributes after converting my scalars to Dynamic Data. Looking at the LVM file in a text editor, I think everything now makes sense at that level.
However, when I read the data back with "Read from Measurement File" and display it on a waveform chart, my starting timestamp is correct, but the displayed duration is 2x too long. But if I select the Relative Timestamps option in the "Read from Measurement File" express VI configuration, the displayed duration is correct. ??? Of course I want to display Absolute Timestamps...
Is this a bug, or am I just doing something wrong? Is there a simpler way to do what I want? This was supposed to be quick-and-dirty...
All my code is attached. I'm using LabVIEW 2015 SP1 running on Windows 7 / 32.
Thanks in advance for any help!
-- Philip
Solved! Go to Solution.
09-16-2016 11:09 AM
Dump the "Express" VI's, they were really only developed for the one day LabVIEW "seminars" (sales pitches) to show how fast you can just throw something together.
Use the standard primitives and you will have a lot more control of how the data is stored, timestamped, and displayed when read back..
09-19-2016 01:15 AM
Normally I'm no big fan of Express VIs, but here I was just trying to instrument existing programs for a long measurement run, and a super-quick solution would have been very welcome. Failing that, I don't have much choice but to try something more complicated.
09-25-2016 06:43 AM
A brief update: I also submitted a support request on this issue, and the NI rep verified that it is a bug, and has submitted a CAR. In the meantime, I used the Datalog VIs, and found that those did what I needed, with relatively little fuss.