atsamd_hal::sercom::pad

Trait GetOptionalPad

Source
pub trait GetOptionalPad<S: Sercom>: OptionalPinId {
    type PadNum: OptionalPadNum;
    type Pad: OptionalPad;
}
Expand description

Type-level function mapping OptionalPinIds to their corresponding OptionalPads

This trait acts as a [type-level function] mapping OptionalPinIds to their corresponding OptionalPad. In pseudo-Rust, it is the type-level equivalent of starting with Option<PinId> and calling .map(GetPad) to recover an Option<Pad>.

Required Associated Types§

Implementors§

Source§

impl<S, I> GetOptionalPad<S> for I
where S: Sercom, I: PinId + GetPad<S>, Pad<S, I>: IsPad,

Source§

type PadNum = <I as GetPad<S>>::PadNum

Source§

type Pad = Pin<I, <I as GetPad<S>>::PinMode>

Source§

impl<S: Sercom> GetOptionalPad<S> for NoneT