Trait kernel::hil::gpio::Input

source ·
pub trait Input {
    // Required method
    fn read(&self) -> bool;

    // Provided method
    fn read_activation(&self, mode: ActivationMode) -> ActivationState { ... }
}

Required Methods§

source

fn read(&self) -> bool

Get the current state of an input GPIO pin. For an output pin, return the output; for an input pin, return the input; for disabled or function pins the value is undefined.

Provided Methods§

source

fn read_activation(&self, mode: ActivationMode) -> ActivationState

Get the current state of a GPIO pin, for a given activation mode.

Implementors§

source§

impl<'a, IP: InterruptPin<'a>> Input for InterruptValueWrapper<'a, IP>