LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Save Digital Data to a Text File

I have digital data collected from two ports simultaneously as N number of samples in waveform that I do calculations on to get a result. I would like to save the raw data in a text file so that it can be easily viewed in an external program, like Excel.  This file would be used as verification of the result calculated in my program. I would think this would be a simple thing to do in labview but as yet have not figured it out. I’ve tried to change the digital to analog and then save as a text file but the data no longer gives the same results when recalculated in an external program. Thanks for any input on this subject.

 

Tessa

0 Kudos
Message 1 of 15
(4,608 Views)
Did you try the "Write to Spreadsheet File.vi" in the File I/O pallate?
0 Kudos
Message 2 of 15
(4,602 Views)
If you have and it didn't work, let us know the exact data type of the raw data and how you wanted it to be formated in a file.  For example, is the data booleans, integers, doubles and what are the array dimensions etc.  There are lots of options as how to do this.

Message Edited by paulmw on 11-16-2006 07:40 AM

0 Kudos
Message 3 of 15
(4,581 Views)

Tessa

Try Export Waveforms to Spreadsheet File.vi in the Waveform I/O Palette.

David

 

Message 4 of 15
(4,581 Views)

The write to spreadsheet file only excepts values of double precision and even when I extract only the Y component of the waveform it gives a broken wire. I would still need to convert from digital to analog.

 

Tessa

0 Kudos
Message 5 of 15
(4,579 Views)

I am doing a Digital 1D Waveform N Channel N sample read with DAQmx of two different lines. The output is a 2D array of waveforms. I separate the two lines with a pair of Index array VIs then extract the Y-Componet to search for the index where my event happens and complete my calculations on that.

Tessa

0 Kudos
Message 6 of 15
(4,561 Views)

The Export to spreadsheet VI is only for analog waveforms not digital, I too thought I could just convert from digital to analog and use the Export to spreadsheet VI, but I didn't get the same result from the external program, ie Excel.

Tessa

0 Kudos
Message 7 of 15
(4,559 Views)

Which version of labview are you using? There are more functions in 8.0 above that should be able to help you.

Also, can you post your code or at least a jpg of your block diagram. I would like to get a better picture of where you are at the moment.

thanks

David

0 Kudos
Message 8 of 15
(4,552 Views)
I am using 8.20. 
 
Thanks, Tessa
0 Kudos
Message 9 of 15
(4,544 Views)

OK thanks for that. Could you do this for me now?

1. Populate a Digital Waveform Control with the data you are trying to save.

2. Cut and paste the Digital Waveform Control with the data into a new vi.

3. Right click on the control and Data Operations -> Make Current Value Default

4. Save the new vi and post it.

This will give me data to work with.

thanks

David

0 Kudos
Message 10 of 15
(4,538 Views)