pub struct OutputOpenDrain<'d> { /* private fields */ }Expand description
GPIO output open-drain driver.
Note that pins will return to their floating state when OutputOpenDrain is dropped.
If pins should retain their state indefinitely, either keep ownership of the
OutputOpenDrain, or pass it to core::mem::forget.
Implementations§
Source§impl<'d> OutputOpenDrain<'d>
impl<'d> OutputOpenDrain<'d>
Sourcepub fn is_set_high(&self) -> bool
pub fn is_set_high(&self) -> bool
Get whether the output level is set to high.
Sourcepub fn is_set_low(&self) -> bool
pub fn is_set_low(&self) -> bool
Get whether the output level is set to low.
Sourcepub fn get_output_level(&self) -> Level
pub fn get_output_level(&self) -> Level
Get the current output level.
Trait Implementations§
Source§impl<'d> ErrorType for OutputOpenDrain<'d>
impl<'d> ErrorType for OutputOpenDrain<'d>
Source§type Error = Infallible
type Error = Infallible
Error type
Source§impl<'d> InputPin for OutputOpenDrain<'d>
impl<'d> InputPin for OutputOpenDrain<'d>
Source§impl<'d> InputPin for OutputOpenDrain<'d>
impl<'d> InputPin for OutputOpenDrain<'d>
Source§impl<'d> OutputPin for OutputOpenDrain<'d>
impl<'d> OutputPin for OutputOpenDrain<'d>
Source§type Error = Infallible
type Error = Infallible
Error type
Source§impl<'d> OutputPin for OutputOpenDrain<'d>
impl<'d> OutputPin for OutputOpenDrain<'d>
Source§impl<'d> StatefulOutputPin for OutputOpenDrain<'d>
impl<'d> StatefulOutputPin for OutputOpenDrain<'d>
Source§impl<'d> StatefulOutputPin for OutputOpenDrain<'d>
impl<'d> StatefulOutputPin for OutputOpenDrain<'d>
Source§impl<'d> ToggleableOutputPin for OutputOpenDrain<'d>
impl<'d> ToggleableOutputPin for OutputOpenDrain<'d>
Auto Trait Implementations§
impl<'d> Freeze for OutputOpenDrain<'d>
impl<'d> RefUnwindSafe for OutputOpenDrain<'d>
impl<'d> Send for OutputOpenDrain<'d>
impl<'d> Sync for OutputOpenDrain<'d>
impl<'d> Unpin for OutputOpenDrain<'d>
impl<'d> !UnwindSafe for OutputOpenDrain<'d>
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more