Electrical – STM32F10x RTC Clock Source

rtcstm32stm32f10x

I have been trying to implement calendar functionality on my STM32f103C8 using the built in RTC peripheral.

Going through the RTC section of the reference manual, it states that the clock source to RTC can be either of HSE/128 or LSE or LSI. So far so good.

But then I found this regarding RTC in the RCC section

enter image description here

What do they mean by "RTC state is not guranteed if the Vdd supply is powered off…" when using HSE/128 as the RTC clock source? I was under the impression that as long as the BACKUP domain is not resetted (Vbat present if Vdd turned off), the RTC state would be maintained. Isn't that the whole point of RTC?

Best Answer

Yes, and if you use the LSE clock, everything is fine. This blurb is telling you that if you choose an alternate clock source for the RTC, such as HSE or LSI you will NOT be fine.

A lot of applications just need to keep track of runtime, and so don't have a 32k crystal or anything like that to maintain time across power cycles. For THOSE applications, LSI or HSE clock sources are adequate. It sounds like that's not a good way to go for you though.