LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Can I acquire time signal along with signal from pressure transducer simultaneously with DAQ assistant?

Hi,

 

I am acquiring signals from two pressure transducers using the LabVIEW 8.6 DAQ Assistant and am wondering if I can also acquire a signal for time that can also be output to a .txt file to be imported into Excel.  Also, I was wondering how I can get my time axis on my waveform graphs to change as time goes on.  Currently, the data from the pressure transducers is being acquired continuously but it just starts over on the time axis (e.g. 0 - 20ms and then repeats over the same interval).  I may have been a little vague and some of what I said may need clarification.  Just let me know if this is the case.

 

Thank You,

bsteinma 

0 Kudos
Message 1 of 2
(2,552 Views)

Hi bsteinma,

 

By default, the waveform graph will just graph the set of samples that is given to it, which will be changing for each iteration as you read new samples, and it formats the time axis to correspond to the dt value of the waveform. You can actually change this to display the absolute time by right-clicking on the graph and selecting Properties. In the properties window, select the Display Format tab and make sure the x-axis is selected (please see attached screenshot "graph_properties.png" ). You can then select absolute time, and you will see the axis change to correspond to the actual time of your measurement (based on the t0 and dt values of the waveform). However, even with this method, you will still only be graphing the last set of data you read. If you want to see the data accumulate with time, you will need to use a shift register and keep building an array with data (not ideal for long period of time as the array gets large and needs to be graphed each time), or use a waveform chart instead.

 

Regarding your initial question about writing the time values, I would suggest using the Export Waveforms to Spreadsheet File VI, which can be found in your functions palette under Programming » Waveform » Waveform File I/O. You can just wire your waveforms to this VI and specify to append the data to the file (please see attached screenshot "wfm_sprdsheet.png" ). I also prefer to turn off writing the header, otherwise a header will be inserted into the file for each loop iteration and it is not as clean. Also note that you will have to change the formatting of the cells in Excel to display the time properly (I had to create a custom format of the form h:mm:ss.000 AM/PM to view the time with the proper millisecond resolution). Please let me know if this answers your question, or at least provides a good starting point.

 

Regards,
Daniel S.
National Instruments
Download All
Message 2 of 2
(2,527 Views)