stm32: add stm32c0 support.

This commit is contained in:
Dario Nieuwenhuis
2023-01-17 18:54:23 +01:00
parent aea5a0fd96
commit 2a349afea7
10 changed files with 277 additions and 29 deletions

View File

@ -10,6 +10,7 @@ use crate::time::Hertz;
#[cfg_attr(rcc_f3, path = "f3.rs")]
#[cfg_attr(any(rcc_f4, rcc_f410), path = "f4.rs")]
#[cfg_attr(rcc_f7, path = "f7.rs")]
#[cfg_attr(rcc_c0, path = "c0.rs")]
#[cfg_attr(rcc_g0, path = "g0.rs")]
#[cfg_attr(rcc_g4, path = "g4.rs")]
#[cfg_attr(any(rcc_h7, rcc_h7ab), path = "h7.rs")]
@ -30,9 +31,9 @@ pub struct Clocks {
// APB
pub apb1: Hertz,
pub apb1_tim: Hertz,
#[cfg(not(rcc_g0))]
#[cfg(not(any(rcc_c0, rcc_g0)))]
pub apb2: Hertz,
#[cfg(not(rcc_g0))]
#[cfg(not(any(rcc_c0, rcc_g0)))]
pub apb2_tim: Hertz,
#[cfg(any(rcc_wl5, rcc_wle, rcc_u5))]
pub apb3: Hertz,