Showing results for 
Search instead for 
Did you mean: 

log data to a file

The attached vi is wroking as I need and displaying data correctly on a X/Y graph.  I cannot figure out how to effectively write both y values along with their time stamp to a log file.  Any help or suggestions would be appreciated.  Thanks.

0 Kudos
Message 1 of 7

if you could post a the vi in labview 2009 or post a snippet, I might be able to help.

Kudos are (always) welcome for the good post. 🙂
0 Kudos
Message 2 of 7

I saved it as version 9.  Can you work with that?  I also posted a jpg.  Tahnks for the help.

Download All
0 Kudos
Message 3 of 7

Your VI is still in LV2011 and I can not open it. Looking at the snippet of your code, I would recommend using tdms file format, which would be easier to work with. You would just need to input the bundled data to the tdms write and set the channel names according to the order. refer to tdms write examples in labview for more idea. Hope it helps.

Kudos are (always) welcome for the good post. 🙂
0 Kudos
Message 4 of 7

Hey Jootbox,


There are a lot of different ways to accomplish this. A simple start would be to take a look at the Write to Measurement This express VI is able to work with a variety of different inputs and can output a couple different file formats (LVM, TDMS, TDM). It would be best at this point to specify how you want to format your file output. Im guessing you want it to have 1 timestamp value with two corresponding digitial values? Something like this,


time          value 1           value 2


0                   5                       5

.1                  5                       5

.2                  0                       5


Is this the kind of format you want? If so you may want to combine the acquisition of your digital channels into 1 task.


Then write the output of this task to a file. It should automatically append a timestamp when you're writing to a TDMS file.


Tim A.
0 Kudos
Message 5 of 7

Easiest starting point is to use the vi Write To Measurment   You just attach your data to the signals input and select how you want it to work.  If you need anything more than that it gets more complicated, because doing the simple stuff in labview is what is difficult.

0 Kudos
Message 6 of 7

Please have a look at the NI TDMS File Format document to get an overview what's possible with TDMS. You might want to concentrate on the LabVIEW section first and follow the link to the Introduction to LabVIEW TDM Streaming VIs - which is the next step in case "Write To Measurment" is not sufficient

0 Kudos
Message 7 of 7