I am trying to implement BLE mesh Time model. The time data received from the mesh is in TAI format and i need to use local RTC to keep track of this time. For this, I have to convert the TAI time from mesh to UTC locally so that my node can keep track of time using RTC. I'm looking for a generic C source file that would do this before jumping into implementation. Can anyone suggest if it's already there?
Asked
Active
Viewed 406 times
3
-
2According to wikipedia, TAI is exactly 37 seconds ahead of UTC: https://en.wikipedia.org/wiki/International_Atomic_Time#:~:text=It%20is%20the%20principal%20realisation,37%20seconds%20ahead%20of%20UTC. – Michael Kotzjan May 05 '21 at 06:56
-
https://github.com/chmike/posix_tai_time_converter this can convert TAI to posix time format. Maybe it helps you – Michael Kotzjan May 06 '21 at 05:54
-
"According to wikipedia, TAI is exactly 37 seconds ahead of UTC" | Currently and only since 2017-01-01, the date the last leap second was introduced into UTC. The next leap second (none is scheduled for the next possible date, 2022-07-01) will change that. – MaxNoe May 12 '22 at 07:55