/// Returns an iterator over the possible serial reception pins for this port.
Returns an iterator over the possible serial reception pins for this port.
Returns an iterator over the possible serial reception pins for this port .
pub fn serial_rx(port: &Port) -> Box<dyn Iterator<Item = PeripheralPin>> {
    match port {
        Port::Stm32F412 => Box::new(IntoIter::new([
            PeripheralPin::new(Cow::from("USART1"), Cow::from("b"), 3, 7),
            PeripheralPin::new(Cow::from("USART1"), Cow::from("b"), 7, 7),
            PeripheralPin::new(Cow::from("USART1"), Cow::from("a"), 10, 7),
            PeripheralPin::new(Cow::from("USART2"), Cow::from("a"), 3, 7),
            PeripheralPin::new(Cow::from("USART2"), Cow::from("d"), 6, 7),
            PeripheralPin::new(Cow::from("USART6"), Cow::from("c"), 7, 8),
            PeripheralPin::new(Cow::from("USART6"), Cow::from("a"), 12, 8),
            PeripheralPin::new(Cow::from("USART6"), Cow::from("g"), 9, 8),
        ])),
        Port::Wgm160P => Box::new(None.into_iter()),
    }
}
pub fn serial_rx ( port : & Port ) -> Box < dyn Iterator < Item = PeripheralPin > > { match port { Port :: Stm32F412 => Box :: new ( IntoIter :: new ( [ PeripheralPin :: new ( Cow :: from ( " " ) , Cow :: from ( " " ) , 3 , 7 ) , PeripheralPin :: new ( Cow :: from ( " " ) , Cow :: from ( " " ) , 7 , 7 ) , PeripheralPin :: new ( Cow :: from ( " " ) , Cow :: from ( " " ) , 10 , 7 ) , PeripheralPin :: new ( Cow :: from ( " " ) , Cow :: from ( " " ) , 3 , 7 ) , PeripheralPin :: new ( Cow :: from ( " " ) , Cow :: from ( " " ) , 6 , 7 ) , PeripheralPin :: new ( Cow :: from ( " " ) , Cow :: from ( " " ) , 7 , 8 ) , PeripheralPin :: new ( Cow :: from ( " " ) , Cow :: from ( " " ) , 12 , 8 ) , PeripheralPin :: new ( Cow :: from ( " " ) , Cow :: from ( " " ) , 9 , 8 ) , ] ) ) , Port :: Wgm160P => Box :: new ( None . into_iter ( ) ) , } }
Returns an iterator over the possible serial reception pins for this port.
Returns an iterator over the possible serial reception pins for this port .
port
&Port