I just wrote my first library and wanted to share it with you.
I know that there are libraries out that already provide those functions, but I wanted to write my own rather than use an existing one, just for learning purpose
The library provides the following features:
- give back debounced button state (as long as button is pressed)
- give back rising edge (only one program cycle)
- give back rising edge when double pressed (only one program cycle)
- give back held button state (as long as button is held)
- give back rising edge when button is held (only one program cycle)
Debounce-Time, Double Click-Gap and Hold Delay are defaulted to 20, 500 and 1000ms but are changeable of course.
If you have feedback go for it