evert-arias / EasyButton

Arduino library for debouncing momentary contact switches, detect press, release, long press and sequences with event definitions and callbacks.
https://easybtn.earias.me
MIT License
452 stars 63 forks source link

Exception InstrFetchProhibited when calling read with no ISR defined #51

Closed console-netsphere closed 3 years ago

console-netsphere commented 3 years ago

I am having an exception when calling read() when no interrupt handler is passed to the library. The code causing this issue is _pressed_callback() in the file EasyButton.cpp. I don't know if that is a real issue, or I'm doing something wrong.

console-netsphere commented 3 years ago

Fixed by commenting the call to is _pressed_callback().