#include <GpioDebounce.h>
A debounced reading from a Gpio.
GpioDebounce::GpioDebounce |
( |
unsigned int |
interval, |
|
|
unsigned int |
channel |
|
) |
| |
Same as setup(), but throws on error.
int GpioDebounce::setup |
( |
unsigned int |
interval, |
|
|
unsigned int |
channel |
|
) |
| |
Set up the Gpio and debouncer.
- Parameters
-
debounce | the number of calls to process() during which changes are ignored after a change in the input vaulue has been detected. |
channel | the GPIO channel, as passed to Gpio::open() |
- Returns
- 0 on success or an error code otherwise.
bool GpioDebounce::process |
( |
void |
| ) |
|
|
inline |
Read an input from the Gpio and provide an output.
The documentation for this class was generated from the following files: