[][src]Trait rmicrobit::buttons::debouncing::Debounce

pub trait Debounce: Default {
    fn debounce(&mut self, pressed_state: bool) -> bool;
}

A debouncing algorithm and an associated state.

Required methods

fn debounce(&mut self, pressed_state: bool) -> bool

Accepts new polled data and returns the 'debounced' state.

pressed_state true indicates that the button is closed.

Loading content...

Implementors

impl Debounce for CountingDebouncer[src]

impl Debounce for TrivialDebouncer[src]

Loading content...