04-15-2013 09:23 AM
Hello, I am trying to create a "Strip Chart Recorder" application using LabVIEW 2012 SP1 and a Compact DAQ system. I have not been able to get the correct Date/Time to display in the "TDMS - File Viewer.vi" waveform graph, x axis. All of the examples provided with this version of LabVIEW show incorrect Data/Time information as well. It seems that the date/time information is only correct when writing the TDMS using DAQmx (DAQmx Configure Logging.vi). I cannot use this approach because I need to add annotations to the TDMS while running (pass/fail and user annotations).
I have spent way to much Date/Time on this already. Just run the LabVIEW example "TDMS - Express write data (time and frequency domain).vi". Run it for 10 seconds. The viewer graph will show that it ran for 58 seconds! Don't forget to click "Settings..." and load all values in (graph).
I did try to modify the viewer using xScale,Offset and Multiplier, but that didn't work either.
Can someone please help? Thanks.
04-16-2013 12:58 AM
In TDMS - Express write data (time and frequency domain).vi, the data came from the "simulated Signal1(2)" VIs, you can double click the VI and will find that the "samples per second (Hz)" is set to 1000 and number of samples is 100. Thus, TDMS File Viewer will not show the real world time passing as the x axis but values in the interval of 0.001 in the graph.
You should adjust the waveform that logged into TDMS file according to your requirements.
04-16-2013 07:42 AM
Thanks deppSu,
I was planning to write the TDMS data at different rates, so I need the Date/Time to follow the various sample rates. A better example might be the LabVIEW "TDMS - Write data (time domain).vi" found in examples. In this example, the start Date/Time is 12/31/1903 @ 4PM. Using that example, can someone show me how to make the Date/Time in the TDMS - File Viewer.vi show the current, and correct Date/Time?
Thanks again.
04-16-2013 09:22 PM - edited 04-16-2013 09:22 PM
If you are logging the data as a waveform, then you can update the start-time by setting property "wf_start_time".
Thanks,
zaizhou.ma