pub struct Pads<S, DI = NoneT, DO = NoneT, CK = NoneT, SS = NoneT>where
S: Sercom,
DI: OptionalPad,
DO: OptionalPad,
CK: OptionalPad,
SS: OptionalPad,{ /* private fields */ }
Expand description
Container for a set of SERCOM pads
See the module-level documentation for more details on declaring
and instantiating Pads
types.
Implementations
sourceimpl<S, DI, DO, CK, SS> Pads<S, DI, DO, CK, SS>where
S: Sercom,
DI: OptionalPad,
DO: OptionalPad,
CK: OptionalPad,
SS: OptionalPad,
impl<S, DI, DO, CK, SS> Pads<S, DI, DO, CK, SS>where
S: Sercom,
DI: OptionalPad,
DO: OptionalPad,
CK: OptionalPad,
SS: OptionalPad,
sourcepub fn free(self) -> (DI, DO, CK, SS)
pub fn free(self) -> (DI, DO, CK, SS)
sourceimpl<S, DI, DO, CK, SS> Pads<S, DI, DO, CK, SS>where
S: Sercom,
DI: OptionalPad,
DO: OptionalPad,
CK: OptionalPad,
SS: OptionalPad,
impl<S, DI, DO, CK, SS> Pads<S, DI, DO, CK, SS>where
S: Sercom,
DI: OptionalPad,
DO: OptionalPad,
CK: OptionalPad,
SS: OptionalPad,
sourcepub fn data_in<I>(
self,
pin: impl AnyPin<Id = I>
) -> Pads<S, Pad<S, I>, DO, CK, SS>where
I: GetPad<S>,
Pad<S, I>: IsPad,
pub fn data_in<I>(
self,
pin: impl AnyPin<Id = I>
) -> Pads<S, Pad<S, I>, DO, CK, SS>where
I: GetPad<S>,
Pad<S, I>: IsPad,
Set the DI
pad
In a MasterMode
, this is MISO. In Slave
OpMode
, this is
MOSI.
sourcepub fn data_out<I>(
self,
pin: impl AnyPin<Id = I>
) -> Pads<S, DI, Pad<S, I>, CK, SS>where
I: GetPad<S>,
Pad<S, I>: IsPad,
pub fn data_out<I>(
self,
pin: impl AnyPin<Id = I>
) -> Pads<S, DI, Pad<S, I>, CK, SS>where
I: GetPad<S>,
Pad<S, I>: IsPad,
Set the DO
pad
In a MasterMode
, this is MOSI. In Slave
OpMode
, this is
MISO.
Trait Implementations
sourceimpl<S, DI, DO, CK, SS> DipoDopo for Pads<S, DI, DO, CK, SS>where
S: Sercom,
DI: OptionalPad,
DO: OptionalPad,
CK: OptionalPad,
SS: OptionalPad,
(DI::PadNum, DO::PadNum, CK::PadNum, SS::PadNum): DipoDopo,
impl<S, DI, DO, CK, SS> DipoDopo for Pads<S, DI, DO, CK, SS>where
S: Sercom,
DI: OptionalPad,
DO: OptionalPad,
CK: OptionalPad,
SS: OptionalPad,
(DI::PadNum, DO::PadNum, CK::PadNum, SS::PadNum): DipoDopo,
Lift the implementations of DipoDopo
from four-tuples of
OptionalPadNum
s to the corresponding Pads
types.
sourceimpl<S, DI, DO, CK, SS> PadSet for Pads<S, DI, DO, CK, SS>where
S: Sercom,
DI: OptionalPad,
DO: OptionalPad,
CK: OptionalPad,
SS: OptionalPad,
impl<S, DI, DO, CK, SS> PadSet for Pads<S, DI, DO, CK, SS>where
S: Sercom,
DI: OptionalPad,
DO: OptionalPad,
CK: OptionalPad,
SS: OptionalPad,
sourceimpl<S, DI, DO, CK, SS> ValidPads for Pads<S, DI, DO, CK, SS>where
S: Sercom,
DI: SomePad,
DO: SomePad,
CK: SomePad,
SS: OptionalPad,
Pads<S, DI, DO, CK, SS>: DipoDopo,
impl<S, DI, DO, CK, SS> ValidPads for Pads<S, DI, DO, CK, SS>where
S: Sercom,
DI: SomePad,
DO: SomePad,
CK: SomePad,
SS: OptionalPad,
Pads<S, DI, DO, CK, SS>: DipoDopo,
type Capability = Duplex
Auto Trait Implementations
impl<S, DI, DO, CK, SS> RefUnwindSafe for Pads<S, DI, DO, CK, SS>where
CK: RefUnwindSafe,
DI: RefUnwindSafe,
DO: RefUnwindSafe,
S: RefUnwindSafe,
SS: RefUnwindSafe,
impl<S, DI, DO, CK, SS> Send for Pads<S, DI, DO, CK, SS>where
CK: Send,
DI: Send,
DO: Send,
S: Send,
SS: Send,
impl<S, DI, DO, CK, SS> Sync for Pads<S, DI, DO, CK, SS>where
CK: Sync,
DI: Sync,
DO: Sync,
S: Sync,
SS: Sync,
impl<S, DI, DO, CK, SS> Unpin for Pads<S, DI, DO, CK, SS>where
CK: Unpin,
DI: Unpin,
DO: Unpin,
S: Unpin,
SS: Unpin,
impl<S, DI, DO, CK, SS> UnwindSafe for Pads<S, DI, DO, CK, SS>where
CK: UnwindSafe,
DI: UnwindSafe,
DO: UnwindSafe,
S: UnwindSafe,
SS: UnwindSafe,
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more