pub trait Api: Support<usize> + Send {
    // Required methods
    fn get(led: Id<Self>) -> Result<bool, Error>;
    fn set(led: Id<Self>, on: bool) -> Result<(), Error>;
}
Available on crate feature api-led only.
Expand description

LED interface.

Required Methods§

source

fn get(led: Id<Self>) -> Result<bool, Error>

Returns whether a given LED is on.

source

fn set(led: Id<Self>, on: bool) -> Result<(), Error>

Sets the state of a given LED.

Object Safety§

This trait is not object safe.

Implementors§