Browse Source

Add rcc to stm32f030

features/pwm
David Sawatzke 4 years ago
parent
commit
5d4a841a46
  1. 6
      src/rcc.rs

6
src/rcc.rs

@ -1,6 +1,6 @@
use core::cmp;
#[cfg(feature = "stm32f042")]
#[cfg(any(feature = "stm32f042", feature = "stm32f030"))]
use crate::stm32::{FLASH, RCC};
use cast::u32;
@ -12,7 +12,7 @@ pub trait RccExt {
fn constrain(self) -> Rcc;
}
#[cfg(feature = "stm32f042")]
#[cfg(any(feature = "stm32f042", feature = "stm32f030"))]
impl RccExt for RCC {
fn constrain(self) -> Rcc {
Rcc {
@ -38,7 +38,7 @@ pub struct CFGR {
sysclk: Option<u32>,
}
#[cfg(feature = "stm32f042")]
#[cfg(any(feature = "stm32f042", feature = "stm32f030"))]
impl CFGR {
pub fn hclk<F>(mut self, freq: F) -> Self
where

Loading…
Cancel
Save