LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

which data recording method: write to spreadsheet func. or write to text func.?

I do not know much about recording data to text or spreadsheet. I need to record measurements in  47 columns and 20000-30000 rows. All data are double precision. I attached a screen shot that is explaining the methods by which I want to log data. Which one is the best for this case? Using write to spreadsheet function or write to text?

Egemen
0 Kudos
Message 1 of 7
(2,540 Views)

Hi newbieeng,

 

for that amount of data you should write each row of data to the file in the loop (data safety, smaller memory requirements).

 

It doesn't matter (in terms of resulting file) which function you use, you can also attach data to existing file using WriteToSpreadsheetFile.

When speed really matters you should use separate loops for DAQ and file writing and you should think about using TDM(S) or binary files...

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 2 of 7
(2,527 Views)

On my last project I had alot of success with tdms logging alot of channels so in my opinion that would be the way to go, may be worth you looking into it to see if it fits your application

Please remember to accept any solutions and give kudos, Thanks


LV 8.6.1, LV2010,LV2011SP1, FPGA, Win7
0 Kudos
Message 3 of 7
(2,522 Views)

Thank you all for your replies.

 

GerdW, what do you mean separating loops for daq and logging data? A kind of state machine? First acquire data and after recording it?

Egemen
0 Kudos
Message 4 of 7
(2,517 Views)

Hi Egemen,

 

no, that one is usually called "producer consumer pattern"...

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 5 of 7
(2,513 Views)

Use TDMS instead of spreadsheet. It has a much better performance.

Most applications in measuring space accept TDMS files. Even import into Excel is possible by using the free TDM Excel Add-In.

 

Please do not forget to attach descriptive information (meta data) in terms of properties (name/value pairs) for documentation, report generation and data mining.

Data without attached descriptive information will become useless over time.

 

In case you have to stick with a spreadsheet, also consider adding descriptive information. By providing a DataPlugin for this specific file, report generation and data mining is still easy to do.

In this case adding a magic water mark at the beginning of your file, for instance in form of a text (MY_SPREADSHEET_FILE_1_0)  will help to identify this specific spreadsheet file type.

0 Kudos
Message 6 of 7
(2,498 Views)

thank you StefanR, I will check this option.

 

Egemen
0 Kudos
Message 7 of 7
(2,493 Views)