LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Daylight Savings Time Conversion correction.


 I have a question.  Will I need to make the following correction each year after/belore daylight savings time??  If so, is there a way to make this change programmatically?

 

http://digital.ni.com/public.nsf/allkb/95CA7D76758B736B8625777C006C7934

 

Thank you, John

0 Kudos
Message 1 of 7
(3,649 Views)

LV returns a time stamp as a number of seconds elapsed from a given absolute origin date; the document you are referring to is only concerning how the absolute date/time is shown to the user: taking into account or not the DST (you may also show it in UTC). So what kind of correction do you mean?

Paolo
-------------------
LV 7.1, 2011, 2017, 2019, 2021
0 Kudos
Message 2 of 7
(3,635 Views)

The onboard time (the time stamp in the files) is GMT for our application.  The hope is we could find a solution without having to prompt the user (once a year) to change to DST.

0 Kudos
Message 3 of 7
(3,609 Views)

Look at the Date/Time to Seconds function and its inverse.  It uses a cluster to get a timestamp or visa versa.  This will help you tell if DST is used.  If you have a timestamp already, I'm pretty sure LabVIEW accounts for DST already.  But use these functions to make sure.



There are only two ways to tell somebody thanks: Kudos and Marked Solutions
Unofficial Forum Rules and Guidelines
"Not that we are sufficient in ourselves to claim anything as coming from us, but our sufficiency is from God" - 2 Corinthians 3:5
0 Kudos
Message 4 of 7
(3,600 Views)

DST.png

0 Kudos
Message 5 of 7
(3,590 Views)

Hi again,  is there not a utility that will convert local machine time to UTC or GMT?

0 Kudos
Message 6 of 7
(3,554 Views)

look at pcardinale's example again.  See that false constant?  That is telling the function to NOT convert to UTC time.  If you set it to TRUE, the output will be in UTC time.



There are only two ways to tell somebody thanks: Kudos and Marked Solutions
Unofficial Forum Rules and Guidelines
"Not that we are sufficient in ourselves to claim anything as coming from us, but our sufficiency is from God" - 2 Corinthians 3:5
0 Kudos
Message 7 of 7
(3,549 Views)