01-14-2016 12:16 PM
Hooovahh,
In my earlier post I said I wanted to learn a little, not a lot! Just kidding, I appreciate the information and it is very useful. I enjoy learning best practices, and it's always better sooner than later!
01-14-2016 12:22 PM
Using the 'create or replace' setting, the old file is replaced if it already exists
Is there any way to have a new file with some suffix added if a file with the name already exists?
For example:
Data File.tdms
Data File-2.tdms
Data File-3.tdms
etc
Thanks!
01-14-2016 12:23 PM
I think you'd have to implement your own logic using the "Check if file or folder exists" function.
01-14-2016 01:36 PM
Starting in 2015 there is actually a "Create File with Incrementing Suffix" which will create a new file name that doesn't overwrite an existing one. It has a few features I wish it didn't (like opening a reference to that new file) but you can open it up, make a new copy, and edit it to your liking.
And as for the TDMS comment, I really enjoy the file format. For the types of data that LabVIEW applications generally produce, they work pretty well. With tools to convert or open in Excel, quickly finding data without needing to read the whole file, fast writing, DMA streaming from DAQ to disk, in memory manipulation, and the fact that NI seems to continue to add new features, it makes sense to at least research and give it a try. An interesting thread on LAVA appeared a while ago where I gave my opinion.
Unofficial Forum Rules and Guidelines
Get going with G! - LabVIEW Wiki.
17 Part Blog on Automotive CAN bus. - Hooovahh - LabVIEW Overlord
10-12-2016 06:08 AM
Would just like to add a hint regarding "traceability" of data in TDMS files;
We found that often circumstances had us looking at old data, and not knowing exactly what calibration constants we had used when obtaining the data. This was true in both text files and TDMS files (losing notes is platform independent). After we got friendly with the functions available in the TDMS we started to store calibration constants in the properties of each data channel. When using waveforms as DAQ output, our calibration subVI (that applies our calibration values) stores channel name and calibration constants in the waveform attribute. The nugget here is that waveform attributes are automatically written to the channel properties of the TDMS.
We could, and probably should, include sensor serial numbers etc. here...
10-12-2016 06:45 AM
was this for me??
07-28-2017 09:55 AM
How do I get the TDMS write to let me attach a array of strings for the names......I cant seem to get this to work.
07-28-2017 10:28 AM
@BBEATON wrote:
How do I get the TDMS write to let me attach a array of strings for the names......
You start by making your own new thread which starts as unanswered. This thread not only doesn't relate to your problem but has been solved. Also reading the context help on the write function, and looking at the examples will help. If you do make a new thread asking a new question, be sure and provide as much details as you can including example code, what version of LabVIEW and OS if applicable, and what you are trying to accomplish.
Unofficial Forum Rules and Guidelines
Get going with G! - LabVIEW Wiki.
17 Part Blog on Automotive CAN bus. - Hooovahh - LabVIEW Overlord