Skip to content

Commit

Permalink
Add missing clock check
Browse files Browse the repository at this point in the history
  • Loading branch information
itswenb committed Nov 27, 2024
1 parent b225d73 commit 09c9f64
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions embassy-stm32/src/rcc/g4.rs
Original file line number Diff line number Diff line change
Expand Up @@ -237,6 +237,7 @@ pub(crate) unsafe fn init(config: Config) {

let (pclk1, pclk1_tim) = super::util::calc_pclk(hclk, config.apb1_pre);
let (pclk2, pclk2_tim) = super::util::calc_pclk(hclk, config.apb2_pre);
rcc_assert!(max::PCLK.contains(&pclk1));
rcc_assert!(max::PCLK.contains(&pclk2));

// Configure Core Boost mode ([RM0440] p234 – inverted because setting r1mode to 0 enables boost mode!)
Expand Down

0 comments on commit 09c9f64

Please sign in to comment.