Skip to content

In this repo I am trying out STM32's RTC peripheral

Notifications You must be signed in to change notification settings

gudnimg/stm32-rtc-test

Repository files navigation

stm32-rtc-test

In this repo I am trying out STM32's RTC peripheral

Reading Material


I'll be playing around with Nucleo L412RB-P

STM32L412RB documents

Important Registers

RTC time register (RTC_TR) Keeps track of hours, minutes, and seconds in BCD format.

RTC date register (RTC_DR) Keeps track of years, week days, months, and date in BCD format.

RTC status register (RTC_SR)

RTC timestamp time register (RTC_TSTR)

Note: The content of this register is valid only when TSF is set to 1 in RTC_SR. It is cleared when TSF bit is reset.

RTC control register (RTC_CR)

RTC status clear register (RTC_SCR)


Why is BCD format used?


Other notes

  • HAL_RTC_GetDate() must be called after HAL_RTC_GetTime() in order for sTime to receive updated values.

About

In this repo I am trying out STM32's RTC peripheral

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages