Struct atsam4_hal::gpio::Pd17

source ·
pub struct Pd17<MODE> { /* private fields */ }

Implementations§

source§

impl<MODE> Pd17<MODE>

source

pub fn downgrade(self) -> PioX<MODE>

Erases the pin number and port from the type

This is useful when you want to collect the pins into an array where you need all the elements to have the same type

source§

impl<MODE> Pd17<MODE>

source

pub fn into_peripheral_function_a(self, _matrix: &MATRIX) -> Pd17<PfA>

source

pub fn into_peripheral_function_b(self, _matrix: &MATRIX) -> Pd17<PfB>

source

pub fn into_peripheral_function_c(self, _matrix: &MATRIX) -> Pd17<PfC>

source

pub fn into_peripheral_function_d(self, _matrix: &MATRIX) -> Pd17<PfD>

source

pub fn into_floating_input(self, _matrix: &MATRIX) -> Pd17<Input<Floating>>

source

pub fn into_pull_down_input(self, _matrix: &MATRIX) -> Pd17<Input<PullDown>>

source

pub fn into_pull_up_input(self, _matrix: &MATRIX) -> Pd17<Input<PullUp>>

source

pub fn into_open_drain_output(self, _matrix: &MATRIX) -> Pd17<Output<OpenDrain>>

Configures the pin to operate as an open drain output

source

pub fn into_push_pull_output(self, _matrix: &MATRIX) -> Pd17<Output<PushPull>>

Configures the pin to operate as a push-pull output

Trait Implementations§

source§

impl<MODE> InputPin for Pd17<Input<MODE>>

§

type Error = Infallible

Error type
source§

fn is_high(&self) -> Result<bool, Self::Error>

Is the input pin high?
source§

fn is_low(&self) -> Result<bool, Self::Error>

Is the input pin low?
source§

impl IoPin<Pd17<Input<Floating>>, Pd17<Output<PushPull>>> for Pd17<Input<Floating>>

§

type Error = Infallible

Error type.
source§

fn into_input_pin(self) -> Result<Self, Self::Error>

Tries to convert this pin to input mode. Read more
source§

fn into_output_pin( self, state: PinState ) -> Result<Pd17<Output<PushPull>>, Self::Error>

Tries to convert this pin to output mode with the given initial state. Read more
source§

impl IoPin<Pd17<Input<Floating>>, Pd17<Output<PushPull>>> for Pd17<Output<PushPull>>

§

type Error = Infallible

Error type.
source§

fn into_input_pin(self) -> Result<Pd17<Input<Floating>>, Self::Error>

Tries to convert this pin to input mode. Read more
source§

fn into_output_pin(self, state: PinState) -> Result<Self, Self::Error>

Tries to convert this pin to output mode with the given initial state. Read more
source§

impl IoPin<Pd17<Input<PullDown>>, Pd17<Output<PushPull>>> for Pd17<Input<PullDown>>

§

type Error = Infallible

Error type.
source§

fn into_input_pin(self) -> Result<Self, Self::Error>

Tries to convert this pin to input mode. Read more
source§

fn into_output_pin( self, state: PinState ) -> Result<Pd17<Output<PushPull>>, Self::Error>

Tries to convert this pin to output mode with the given initial state. Read more
source§

impl IoPin<Pd17<Input<PullDown>>, Pd17<Output<PushPull>>> for Pd17<Output<PushPull>>

§

type Error = Infallible

Error type.
source§

fn into_input_pin(self) -> Result<Pd17<Input<PullDown>>, Self::Error>

Tries to convert this pin to input mode. Read more
source§

fn into_output_pin(self, state: PinState) -> Result<Self, Self::Error>

Tries to convert this pin to output mode with the given initial state. Read more
source§

impl IoPin<Pd17<Input<PullUp>>, Pd17<Output<PushPull>>> for Pd17<Input<PullUp>>

§

type Error = Infallible

Error type.
source§

fn into_input_pin(self) -> Result<Self, Self::Error>

Tries to convert this pin to input mode. Read more
source§

fn into_output_pin( self, state: PinState ) -> Result<Pd17<Output<PushPull>>, Self::Error>

Tries to convert this pin to output mode with the given initial state. Read more
source§

impl IoPin<Pd17<Input<PullUp>>, Pd17<Output<PushPull>>> for Pd17<Output<PushPull>>

§

type Error = Infallible

Error type.
source§

fn into_input_pin(self) -> Result<Pd17<Input<PullUp>>, Self::Error>

Tries to convert this pin to input mode. Read more
source§

fn into_output_pin(self, state: PinState) -> Result<Self, Self::Error>

Tries to convert this pin to output mode with the given initial state. Read more
source§

impl<MODE> OutputPin for Pd17<Output<MODE>>

§

type Error = Infallible

Error type
source§

fn set_high(&mut self) -> Result<(), Self::Error>

Drives the pin high Read more
source§

fn set_low(&mut self) -> Result<(), Self::Error>

Drives the pin low Read more
source§

fn set_state(&mut self, state: PinState) -> Result<(), Self::Error>

Drives the pin high or low depending on the provided value Read more
source§

impl<MODE> StatefulOutputPin for Pd17<Output<MODE>>

source§

fn is_set_high(&self) -> Result<bool, Self::Error>

Is the pin in drive high mode? Read more
source§

fn is_set_low(&self) -> Result<bool, Self::Error>

Is the pin in drive low mode? Read more
source§

impl<MODE> Default for Pd17<Output<MODE>>

Software toggle (uses StatefulOutputPin and OutputPin)

Auto Trait Implementations§

§

impl<MODE> RefUnwindSafe for Pd17<MODE>where MODE: RefUnwindSafe,

§

impl<MODE> Send for Pd17<MODE>where MODE: Send,

§

impl<MODE> Sync for Pd17<MODE>where MODE: Sync,

§

impl<MODE> Unpin for Pd17<MODE>where MODE: Unpin,

§

impl<MODE> UnwindSafe for Pd17<MODE>where MODE: UnwindSafe,

Blanket Implementations§

source§

impl<T> Any for Twhere T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for Twhere T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for Twhere T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

source§

impl<T, U> Into<U> for Twhere U: From<T>,

source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

source§

impl<P> ToggleableOutputPin for Pwhere P: Default,

source§

fn toggle(&mut self) -> Result<(), <P as ToggleableOutputPin>::Error>

Toggle pin output

§

type Error = <P as OutputPin>::Error

Error type
source§

impl<T, U> TryFrom<U> for Twhere U: Into<T>,

§

type Error = Infallible

The type returned in the event of a conversion error.
source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

impl<T, U> TryInto<U> for Twhere U: TryFrom<T>,

§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.