pub trait _atsamd_hal_embedded_hal_digital_v2_OutputPin {
    type Error;

    // Required methods
    fn set_low(&mut self) -> Result<(), Self::Error>;
    fn set_high(&mut self) -> Result<(), Self::Error>;

    // Provided method
    fn set_state(&mut self, state: PinState) -> Result<(), Self::Error> { ... }
}
Expand description

Single digital push-pull output pin

Required Associated Types§

source

type Error

Error type

Required Methods§

source

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

Drives the pin low

NOTE the actual electrical state of the pin may not actually be low, e.g. due to external electrical sources

source

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

Drives the pin high

NOTE the actual electrical state of the pin may not actually be high, e.g. due to external electrical sources

Provided Methods§

source

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

Drives the pin high or low depending on the provided value

NOTE the actual electrical state of the pin may not actually be high or low, e.g. due to external electrical sources

Implementors§

source§

impl OutputPin for DynPin

§

type Error = Error

source§

impl<I, C> OutputPin for sodaq_sara_aff::gpio::v2::Pin<I, Output<C>>where I: PinId, C: OutputConfig,

source§

impl<I, M> OutputPin for sodaq_sara_aff::gpio::Pin<I, Output<M>>where I: PinId, M: OutputConfig,

§

type Error = ()

source§

impl<T> OutputPin for Twhere T: OutputPin,

Implementation of fallible v2::OutputPin for v1::OutputPin traits

§

type Error = ()