Real-Time Measurement and Control

cancel
Showing results for 
Search instead for 
Did you mean: 

What resolution can I expect from the Get Date/Time In Seconds VI running under NI Linux Real Time ?

I am developing a Labview RT application which needs to generate a data timestamp, I was planning on using the Get Date/Time in Seconds but am unsure of the time resolution I could attain running on a CRIO 9068 platform. Does anyone know what resolution I could expect? 

0 Kudos
Message 1 of 3
(4,748 Views)

Dargm, 

 

The Get Date/Time in Seconds VI will return a millisecond value. If you need higher resolution, I would recommend looking into the High Resolution Relative Seconds in the LabVIEW Hidden Gems Library. 

 

Hidden Gems in vi.lib- https://decibel.ni.com/content/groups/hidden-gems-in-vilib

Will M.
Applications Engineer
National Instruments
0 Kudos
Message 2 of 3
(4,726 Views)

Get Data/Time in Seconds actually has microsecond resolution (on NI Linux RT it uses gettimeofday), it's just not displayed in the default indicator which is set to show only to 3 decimal places. If you crank it up to 6 you can see accurate microsecond resolution (increasing to 9 does not show nanosecond resolution on NI Linux RT).

 

On RT targets, for that, you have a couple of extra options besides the hidden gem for higher resolution. In Real-Time>>RT Timing there is a Tick Count VI that has resolution options down to ticks (nanoseconds). Or, depending on your use case, the timestamp functions in the Real-Time palette may be what you want. They have good resolution (nominally nanoseconds, though it takes on the order of nanoseconds to get a timestamp in the first place), and there's a handy utility VI to do typical analysis functions. Those are Real-Time>>RT Utilities>>RT Get Timestamp.vi and Real-Time>>RT Utilities>>RT Timestamp Analysis.vi. Be sure to check the help if you're not familiar with them; they more for benchmarking and probably aren't what you want for timestamping data, but I wanted to mention them for completeness.

Message 3 of 3
(4,652 Views)