cancel
Showing results for 
Search instead for 
Did you mean: 

STM32WB15cc - Wake up periodically with RTC and check for event (battery charged), disable rtc if event has happened

LConn.2
Associate

I am trying to use as little power as possible, I want my board to wake up every 30 seconds or so, check if battery has been sufficiently charged, if not, go back to sleep, if it has then turn off rtc and do a function. Is it possible to disable rtc whilst running?

4 REPLIES 4
Joe WILLIAMS
ST Employee

Dear Liam

Our team is checking into this inquiry and we will be in touch with you shortly.

Kind Regards

Joe WILLIAMS

STMicro Support

Piranha
Chief II

> Is it possible to disable rtc whilst running?

What makes you think the RTCEN bit in RCC_BDCR register cannot be cleared?

Remy ISSALYS
ST Employee

Hello,

You can disable the RTC by setting the RTCSEL in RCC_BDCR register at no clock.

Best Regards

Bits 9:8 RTCSEL[1:0]: RTC clock source selection

Set by software to select the clock source for the RTC. Once the RTC clock source has been selected, it cannot be changed anymore unless the Backup domain is reset, or unless a failure is detected on LSE (LSECSSD is set). The BDRST bit can be used to reset them.