cancel
Showing results for 
Search instead for 
Did you mean: 

RTC example for timestamp (STM32WB55)

kcire L.
Associate III

Hello,

I'm looking for some example code on using the built in RTC for the STM32WB55 to get a timestamp in UNIX UTC Time in milliseconds. Or the number of milliseconds since January 1st 1970.

If anyone has a simple example on how to accomplish this I would greatly appreciate the help.

Thank you in advance.

1 ACCEPTED SOLUTION

Accepted Solutions
Imen.D
ST Employee

Hello @kcire L.​ ,

Maybe you can get inspired from RTC_TimeStamp example within STM32CubeWB MCU package:

\STM32Cube_FW_WB_V1.12.0\Projects\P-NUCLEO-WB55.Nucleo\Examples\RTC\RTC_TimeStamp

This example runs on STM32WB55xx devices and will help you on the RTC configuration using the timestamp feature.

When your question is answered, please close this topic by choosing Select as Best.

Imen

When your question is answered, please close this topic by clicking "Accept as Solution".
Thanks
Imen

View solution in original post

1 REPLY 1
Imen.D
ST Employee

Hello @kcire L.​ ,

Maybe you can get inspired from RTC_TimeStamp example within STM32CubeWB MCU package:

\STM32Cube_FW_WB_V1.12.0\Projects\P-NUCLEO-WB55.Nucleo\Examples\RTC\RTC_TimeStamp

This example runs on STM32WB55xx devices and will help you on the RTC configuration using the timestamp feature.

When your question is answered, please close this topic by choosing Select as Best.

Imen

When your question is answered, please close this topic by clicking "Accept as Solution".
Thanks
Imen