Skip to main content

_embedded_hal_digital_OutputPin

Trait _embedded_hal_digital_OutputPin 

Source
pub trait _embedded_hal_digital_OutputPin {
    // Required methods
    fn set_low(&mut self);
    fn set_high(&mut self);
}
๐Ÿ‘ŽDeprecated since 0.2.2:

Deprecated because the methods cannot return errors. Users should use the traits in digital::v2.

Expand description

Single digital push-pull output pin

This version of the trait is now deprecated. Please use the new OutputPin trait in digital::v2::OutputPin.

Required Methodsยง

Source

fn set_low(&mut self)

๐Ÿ‘ŽDeprecated since 0.2.2:

Deprecated because the methods cannot return errors. Users should use the traits in digital::v2.

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)

๐Ÿ‘ŽDeprecated since 0.2.2:

Deprecated because the methods cannot return errors. Users should use the traits in digital::v2.

Drives the pin high

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

Dyn Compatibilityยง

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementorsยง

Sourceยง

impl<T, E> OutputPin for OldOutputPin<T>
where T: OutputPin<Error = E>, E: Debug,

Implementation of v1::OutputPin trait for fallible v2::OutputPin output pins where errors will panic.