DIAdem

cancel
Showing results for 
Search instead for 
Did you mean: 

how to conjoin tdms files

Solved!
Go to solution

How can you do it using File I/O functions? I have approx. 800 files from 2 months (file created every hour) of testing and need to graph the entire test time. Files have 15 groups having 4 channels each. Sampling was done twice per second.

I need to graph the 4 channels for each group over the two month period.

0 Kudos
Message 11 of 15
(1,688 Views)

My situation is slightly different. I have two Labview programs running simultaneously and taking readings from different sets of sensors, with the same TDMS group name, but different channel names (except for the timestamp). All of the channels except the timestamp are waveforms. When I append the TDMS files using "copy /b" the files are appended by column rather than by row. Is there a way to append/merge by row?

0 Kudos
Message 12 of 15
(942 Views)

@ksmiller99 wrote:

When I append the TDMS files using "copy /b" the files are appended by column rather than by row. Is there a way to append/merge by row?


The two files must have the same group and channel names.  Otherwise you aren't appending data to one channel, you are adding another channel to the file.

 

Also I posted some code here to help with combining files.

https://forums.ni.com/t5/Example-Program-Drafts/TDMS-Combine-and-Rerrange/ta-p/3782888

0 Kudos
Message 13 of 15
(938 Views)

Seems like the "copy /b" trick don't work anymore in windows 11. Do you have a suggestion? Sins our factory is switched to windows 11 this trick don't work with me anymore. 

0 Kudos
Message 14 of 15
(764 Views)

I'm not sure why the copy command wouldn't work in Windows 11, but regardless of that there is a more platform independent way of doing this.  I've taken many of the TDMS tricks I've learned over the years and put them into a Tremendous TDMS toolkit and posted it over on VIPM.IO.

 

https://www.vipm.io/package/hooovahh_tremendous_tdms/

 

Once installed, on the palette is the TDMS File Operations, which has a Combine TDMS Files.  This VI can combine multiple files into one, or append files to an existing file.  It does this by reading the file as a binary file in chunks, then appending that to the other file.  This can be slightly slower than the copy command line function, but is native G so it is cross platform, among other minor benefits.

Message 15 of 15
(738 Views)