LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How to publish the adc sample time on output file, CRIO and NI 9381 module

Solved!
Go to solution

I am a new user to LabVIEW, I am trying to read three ADC channels on NI 9381 module while using NI CRIO in scan interface, I buffered the data and when I stop the running vi it logs data to file, but I am not getting the time for each sample. I need the real-time of the sample when it was taken. Thank you in advance.
my project folder is attached below. 

0 Kudos
Message 1 of 5
(2,497 Views)

Hey,

 

Can you explain what you mean by the real-time of the sample?

 

Thanks,

 

-Brian J.

0 Kudos
Message 2 of 5
(2,458 Views)

Thank you for your time.

By "real time" means the time when actually sample taken from ADC, actually I am facing a problem with only publishing data to a file with the time stamp. while logging data within while loop to a file the time between each sample is different, so I used "shift register" on while loop doing so when I stop the UI it logs all the collected data to file, but doing so it doesn't give the time stamp, only a serial number with each sample.
I appreciate your response.Smiley Happy

0 Kudos
Message 3 of 5
(2,453 Views)
Solution
Accepted by Moonnight786

Hi Moonnight,

 

I am trying to read three ADC channels on NI 9381 module while using NI CRIO in scan interface

I need the real-time of the sample when it was taken.

By "real time" means the time when actually sample taken from ADC

Big problem!

You read your samples using the ScanEngine: the ScanEngine already buffers the data internally!

All you can get is a timestamp from the SharedVariables you use to read those samples, but that most probably is the time you read from the SharedVariable.

The get the "real" (aka "exact") time of the ADC conversion you would need to go down to the FPGA…

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 4 of 5
(2,444 Views)
Thank you for the time, i moved to FPGA i got some libraries and white paper help on Embedded fast data logger from NI, i hope it will get along with me.
0 Kudos
Message 5 of 5
(2,439 Views)