diff options
| -rw-r--r-- | embassy-stm32/src/rcc/l4.rs | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/embassy-stm32/src/rcc/l4.rs b/embassy-stm32/src/rcc/l4.rs index b2828e58e..b34b8caab 100644 --- a/embassy-stm32/src/rcc/l4.rs +++ b/embassy-stm32/src/rcc/l4.rs | |||
| @@ -410,10 +410,11 @@ pub(crate) unsafe fn init(config: Config) { | |||
| 410 | while RCC.cfgr().read().sws() != Sw::MSI {} | 410 | while RCC.cfgr().read().sws() != Sw::MSI {} |
| 411 | } | 411 | } |
| 412 | 412 | ||
| 413 | RCC.apb1enr1().modify(|w| w.set_pwren(true)); | ||
| 414 | |||
| 413 | match config.rtc_mux { | 415 | match config.rtc_mux { |
| 414 | RtcClockSource::LSE32 => { | 416 | RtcClockSource::LSE32 => { |
| 415 | // 1. Unlock the backup domain | 417 | // 1. Unlock the backup domain |
| 416 | RCC.apb1enr1().modify(|w| w.set_pwren(true)); | ||
| 417 | PWR.cr1().modify(|w| w.set_dbp(true)); | 418 | PWR.cr1().modify(|w| w.set_dbp(true)); |
| 418 | 419 | ||
| 419 | // 2. Setup the LSE | 420 | // 2. Setup the LSE |
