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.

LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Timestamp of trigger?

Solved!
Go to solution

I have a DAQmx device taking fixed samples,, on a digital edge, triggered by PFI0 and I can not find how to know or read T0  the exact time of the first sample. 

 

Is there a way to read or make a time stamp of the first sample?

PXI 6115

or

PXIe 6368

0 Kudos
Message 1 of 19
(1,980 Views)

Isn't the T0 in the waveform that the DAQmx Read returns?

0 Kudos
Message 2 of 19
(1,955 Views)

The answer from RavensFan is very likely all you need.  The initial T0 gets calculated the first time you read from your task and it takes into account:

- the "right now" time that the read is happening

- the actual sample rate

- the # of samples read

 

There are certain fairly unusual cases where this estimate isn't quite good enough, but let's not assume you have one of those unless you provide more details to indicate otherwise.   More info here.

 

 

-Kevin P

CAUTION! New LabVIEW adopters -- it's too late for me, but you *can* save yourself. The new subscription policy for LabVIEW puts NI's hand in your wallet for the rest of your working life. Are you sure you're *that* dedicated to LabVIEW? (Summary of my reasons in this post, part of a voluminous thread of mostly complaints starting here).
0 Kudos
Message 3 of 19
(1,939 Views)

We are reading an unscaled Analog 2D, I32, Nchan, Nsamp.  I have never seen waveform data in that.  Is there a way to get it or is it there and I don't see it?

0 Kudos
Message 4 of 19
(1,932 Views)

It is in the polymorphic selector.

 

Capture

0 Kudos
Message 5 of 19
(1,924 Views)

I can't just change what I am reading to get t0.  I need t0 for what I AM reading.

0 Kudos
Message 6 of 19
(1,918 Views)

But you can't get that t0 when you are using a raw, basic setting on your DAQmx read that doesn't provide t0.

 

You certainly can change what you are reading so you can get t0.  Why do you say you can't?

 

What made you pick "unscaled Analog 2D, I32, Nchan, Nsamp" to begin with?

0 Kudos
Message 7 of 19
(1,915 Views)

I have been supporting this program since like 1994.  I started learning Labview for fun on ver 2.5 I think.  I have an expired CLAD but am not a programmer.  I just do it.

 

I am retired and putting my programming days behind me.  This program has seen 4 different A2Ds and it is what it is.   Over 168 sub vis and over 900 total called on launch.

 

The T0 use to come from the Unix system and the VME rack we used in the 90s.  When we went to PC and PXIe I just read the data type in that was needed to match.   I could change it but I am not wanting to do that.   If there is no other way then they can live with the time stamp I make as the data comes out of read.  No one has noticed in 5 years.

0 Kudos
Message 8 of 19
(1,910 Views)

Best I can tell this is not resolved.  I need the data output I need.  It seems like a read from any a2d ever made should give you access to T0 somehow.  

0 Kudos
Message 9 of 19
(1,853 Views)

Hi bob,

 


@bobausttex wrote:

It seems like a read from any a2d ever made should give you access to T0 somehow.  


DAQmx does provide t0 once you switch to "waveform" output.

It's you who sticks to "unscaled integer data"…

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 10 of 19
(1,851 Views)