fix low-power: APB1 needed for LSE

This commit is contained in:
Christian Enderle
2023-09-21 17:17:58 +02:00
parent 5626a28af2
commit ad64d7b20b
2 changed files with 5 additions and 2 deletions

View File

@ -88,6 +88,11 @@ impl BackupDomain {
))]
#[allow(dead_code, unused_variables)]
pub fn configure_ls(clock_source: RtcClockSource, lsi: bool, lse: Option<LseDrive>) {
if lsi || lse.is_some() {
use crate::rtc::sealed::Instance;
crate::peripherals::RTC::enable_peripheral_clk();
}
if lsi {
#[cfg(rtc_v3u5)]
let csr = crate::pac::RCC.bdcr();