From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.
We appreciate your patience as we improve our online experience.
From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.
We appreciate your patience as we improve our online experience.
02-13-2014 01:31 AM
hello all
My TDMS file is around 3g, and needs changed into around 10M size files.
I ran McRorie's splitFiles.vi 15 KB in this page. and set the number of samples per file as 5000000, however, I cannot get the results I need. every small file is only 1KB, and no data inside. What is the possible problem in this?
Also, I tried to write a vi based on sample vi(Read TDMS File) by adding one "write to measurement file.vi". However, when I set the small file size as 10M Byte inside the"write to measurement file.vi", the first file could be around 20M, and the next few files may be correct as 10M, and then it just stop splitting, edding with a file even much larger than original file. I uploaded my vi here, maybe someone can help to find some mistake for me.
Thanks very much!
Wuwei Mao
Solved! Go to Solution.
05-05-2014 03:12 AM - edited 05-05-2014 03:18 AM
Hi Wuwei,
After giving the correct data type to TDMS Read node in splitFiles.vi, it works as expected. ( See the attached two VIs: createFile.vi and the modified splitFiles.vi)
Because I don't know how you created your TDMS file, I write a new 3G bytes TDMS file, which has one group and one channel. The data type of samples is unsigned 16-bit Integer. The total number of samples is 1610612736. Then I set the number of samples per file to 5000000 as you did. So after splitting, each file size is 5000000*(16/8) bytes (around 10M bytes).
Please make sure the followed steps have been done before you run the splitFiles.vi:
1. The TDMS file will be split has been put on the proper path;
2. The correct group and channel names have been given;
3. The correct data type to TDMS Read node has been given.
Because your second option using "write to measurement file.vi" to split TDMS file will lose some information, such as group and channel names. So I suggest using the method used by splitFiles.vi to accomplish your goal.
Jie Zheng
NI R&D
05-05-2014 03:15 AM - edited 05-05-2014 03:24 AM
Adding attachment is not available just now. I will attach createFile.vi and splitFiles.vi when adding attachment works.
05-05-2014 04:50 AM
Hello, Zheng,
Thank you very much for your kind reply.
Yes, I succeeded to split the tdms file now. I made some mistake in the steps you mentioned. it is important to set the correct group name.
Thanks again!
Wuwei Mao