LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Timestamps on AI Read waveform

Hello everyone.
 
I am a total newbie to this board and to LabView in general.
 
What I have so far is, I am reading in an Analog Input through a NI PXI-4472 card.
This I have working nicely, even managing to write data to a file.
I am also reading in GPS time through a ZTec zt1000pxi GPS card.
What I am trying to do is alter the timestamp on the AI Read waveform to reflect GPS time instead of my PC system time.
 
Is there any way to do this?
 
I am attaching my cade so far.
 
Thanks for any help.
0 Kudos
Message 1 of 7
(2,805 Views)
You can use 'Build Waveform' for this.  You wire in your waveform and the t0 input and it will change the waveform's timestamp to the new value of t0.
 
K
LabVIEW Pro Dev & Measurement Studio Pro (VS Pro) 2019 - Unfortunately now moving back to C#, .NET, Python due to forced change to subscription model by NI. 8^{
0 Kudos
Message 2 of 7
(2,782 Views)

Hi NIquist,

I appreciate your response.

 

I have a few questions for you. 

How can I get the components of the waveform from the AI Read function?  I have not been able to get the waveform out of the output by itself to feed into the Build Waveform function.

My next question is how to convert the GPS time to a TIme Stamp that the BUild Waveform function will accept?

When I try to tie the UTC time from the ZT1000 function to the d0 of the Build Waveform function it gives me an error telling me the source is an unsigned 32 bit real and the sink is an extended. So i put in a "To Extended" conversion node, and it then tells me the source is extended and the sink is Time Stamp and it still won't accept it.

Any ideas for getting around this?

 

Sorry for the beginner type questions, but I really havent been able to find any info on my own for using this ZT1000 card for this, or any other, type of process.

 

Thanks a lot.

0 Kudos
Message 3 of 7
(2,771 Views)
AI Read outputs a 1D array of waveforms, one for each channel.  You can only get the properties one array at a time.  You can either index to the waveform you are intersted in, or use a for loop to process them all.

Timestamps are the number of seconds since 12:00 a.m., Friday, January 1, 1904.  You can use this to convert whatever time format the GPS uses with the "To Time Stamp" primative.
0 Kudos
Message 4 of 7
(2,767 Views)
I'm not sure what format your GPS time is in, but you can also set the waveform timestamps using the Date/Time cluster. 


Message Edited by jasonhill on 03-14-2006 01:45 PM

0 Kudos
Message 5 of 7
(2,763 Views)

Hello again,

You guys have been a great help so far and I have (at least) one more question for you.

I found the Waveform to XY Pairs .vi  This is exactly what I need as far as the data I need to collect.  My problem is that I can't get it written to a file I can use.  When I try to write the output to a file using the Write to Spreadsheet File.vi it tells me that my sink is a 2D array and my source is a 1-D array of a cluster of 2 elements.

I havent been able to figure out how to break this out.  The idea I am shooting for is a 2 column Excel sheet with the time stamps in one column and the corresponding data point in the adjacent column.

Any ideas?

Thanks again.

0 Kudos
Message 6 of 7
(2,754 Views)

Just do this.

Message Edited by Dennis Knutson on 03-15-200608:44 AM

0 Kudos
Message 7 of 7
(2,751 Views)