LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Timestamps and Measurement File express VIs

Solved!
Go to solution

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

0 Kudos
Message 1 of 4
(3,541 Views)

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..

========================
=== Engineer Ambiguously ===
========================
0 Kudos
Message 2 of 4
(3,526 Views)

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.

0 Kudos
Message 3 of 4
(3,472 Views)
Solution
Accepted by topic author Keller

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.

0 Kudos
Message 4 of 4
(3,418 Views)