LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

tdms place holders

Solved!
Go to solution

I have written a VI to test AC motors. The VI controls and gathers information from a hypot tester and a power meter. I have the data time stamped also. The program is set up to terminate if the motor under test fails the hypot test. The problem this causes is that the failure data for the hypot test is recorded but the power meter readings are not. When the TDMS file is opened in excel, my test readings after a hypopt failure are no longer aligned with the proper hypot data. The power meter data is shifted up a row. What is the best way to put a place holder into the TDMS data to prevent this from happening.

 

Thanks,  

0 Kudos
Message 1 of 6
(2,749 Views)

Was a channel created twice?  I have seen that if the channel names are identical, data is stored in one column and you will have one column that has more data than the other columns. Also, it would be nice if you posted the code.

0 Kudos
Message 2 of 6
(2,743 Views)

The channel is only created once. I actually setup a state just to write data into the TDMS file. The problem is not in column aligmnment but in the rows. I will need to get to the machine and post the code.

0 Kudos
Message 3 of 6
(2,738 Views)

Here is the VI.

0 Kudos
Message 4 of 6
(2,731 Views)
Solution
Accepted by topic author MwMonty

If the number of elements is not the same as the number of channels you are writing to everytime, your data will be shifted.  In your power case, make sure that the OSI PDM Read Array.vi does output an array of 9 elements for the DATA REGISTER and READ REGISTER.  Simplest fix is to reshape the arrays to the number of channel counts in the ANALYZE case.

 

test.png

 

    

Message 5 of 6
(2,723 Views)

Thanks, this solved the problem.

0 Kudos
Message 6 of 6
(2,660 Views)