LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

TDMS: wf_start_time and time zone

Solved!
Go to solution

I don't understand how the property wf_start_time handles time zone.

It seems that if you open a tdms file you see a time which is in your own time zone (even if the tdms has been saved in a different time zone).

At least this happens if I open the tdms with the excel plugin.

Is this the behavior?

Is this waht is expected by design?

From my side this is not optimal because when the customer has a problem he knows the date and time in its own time zone and I have to convert wf_start_time from my to his time zone.

 

Vix
-------------------------------------------
In claris non fit interpretatio

-------------------------------------------
Using LV from 7
Using LW/CVI from 6.0
0 Kudos
Message 1 of 3
(2,947 Views)
Solution
Accepted by topic author vix

Hi,
here is a couple of articles (and links therein) that you might find useful:

From the latter, in particular,

Timestamps in TDMS files are stored as a structure of two components:

  • (i64) seconds: since the epoch 01/01/1904 00:00:00.00 UTC (using the Gregorian calendar and ignoring leap seconds)
  • (u64) positive fractions: (2^-64) of a second

I have also found an internal NI document which says

TDMS VIs always store time values as UTC, so that the stored value is independent from the current time zone. It might be useful to store the time zone in addition with an additional "UTC_Offset" property (integer).

Hope this helps!

Regards,

Alessia

Message 2 of 3
(2,900 Views)

Thank you,

now everything is clear.

 

I suppose the TDMS Excel Add-In converts the internal timestamp from UTC to localtime based on the local PC;

and this is the reason why I see localtime in Excel.

Vix
-------------------------------------------
In claris non fit interpretatio

-------------------------------------------
Using LV from 7
Using LW/CVI from 6.0
Message 3 of 3
(2,881 Views)