Trait _embedded_hal_digital_v2_StatefulOutputPin

Source
pub trait _embedded_hal_digital_v2_StatefulOutputPin: OutputPin {
    // Required methods
    fn is_set_high(&self) -> Result<bool, Self::Error>;
    fn is_set_low(&self) -> Result<bool, Self::Error>;
}
Expand description

Push-pull output pin that can read its output state

This trait is available if embedded-hal is built with the "unproven" feature.

Required Methods§

Source

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

Is the pin in drive high mode?

NOTE this does not read the electrical state of the pin

Source

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

Is the pin in drive low mode?

NOTE this does not read the electrical state of the pin

Implementors§

Source§

impl<'a, MUTEX, I2C, ERROR> StatefulOutputPin for Pin<'a, Output, MUTEX>
where I2C: WriteRead<Error = ERROR> + Write<Error = ERROR> + Read<Error = ERROR>, MUTEX: BusMutex<Bus = Driver<I2C>>,

Source§

impl<T> StatefulOutputPin for T

Implementation of fallible v2::StatefulOutputPin for v1::StatefulOutputPin digital traits