chrisandreae / RemoteReceiver

Arduino library for receiving data from wireless remote controls with an EV1527 or similar chipset.
BSD 2-Clause "Simplified" License
14 stars 6 forks source link

ISR not in IRAM exception #4

Closed andreyneto closed 3 years ago

andreyneto commented 3 years ago

Hey guy! I bought some cheap Chinese wall buttons (with EV1527 chip), however I am unable to use this lib. I am getting the following exception on the serial monitor:

ISR not in IRAM!

Any ideas how to solve? It would help me a lot!

Originally posted by @andreyneto in https://github.com/chrisandreae/RemoteReceiver/issues/3#issuecomment-763233978

chrisandreae commented 3 years ago

Are you trying to use it on an ESP8266? The library has only been tested on AVR before. Some quick searching suggests that interrupt handlers on ESP8266 need to be declared with ICACHE_RAM_ATTR: try patching that onto RemoteReceiver::interrupt.

Alternatively you could #define REMOTE_RECEIVER_USE_ATTACH_INTERRUPT 0, and arrange for RemoteReceiver::interrupt to be called on pin change events from outside the library.

andreyneto commented 3 years ago

When declaring the handler with ICACHE_RAM_ATTR did not receive the exception anymore, but I still cannot receive any data from my control. Anyway, thanks for the hint!