diff --git a/src/serial.rs b/src/serial.rs index 6905477..9ce94e5 100644 --- a/src/serial.rs +++ b/src/serial.rs @@ -39,14 +39,41 @@ pub enum Error { pub trait Pins {} +#[cfg(any(feature = "stm32f030", feature = "stm32f042"))] impl Pins for (PA9>, PA10>) {} +#[cfg(any(feature = "stm32f030", feature = "stm32f042"))] impl Pins for (PB6>, PB7>) {} +#[cfg(any(feature = "stm32f030", feature = "stm32f042"))] impl Pins for (PA9>, PB7>) {} +#[cfg(any(feature = "stm32f030", feature = "stm32f042"))] impl Pins for (PB6>, PA10>) {} +#[cfg(feature = "stm32f030x6")] +impl Pins for (PA2>, PA3>) {} + +#[cfg(any( + feature = "stm32f042", + feature = "stm32f030x8", + feature = "stm32f030xc", +))] impl Pins for (PA2>, PA3>) {} +#[cfg(any( + feature = "stm32f042", + feature = "stm32f030x8", + feature = "stm32f030xc", +))] impl Pins for (PA2>, PA15>) {} +#[cfg(any( + feature = "stm32f042", + feature = "stm32f030x8", + feature = "stm32f030xc", +))] impl Pins for (PA14>, PA15>) {} +#[cfg(any( + feature = "stm32f042", + feature = "stm32f030x8", + feature = "stm32f030xc", +))] impl Pins for (PA14>, PA3>) {} /// Serial abstraction