neu-rah / ArduinoMenu

Arduino generic menu/interactivity system
GNU Lesser General Public License v2.1
948 stars 191 forks source link

ArduinoMenu with U8G2 crashing the uC ESP32 #359

Open lukilukeskywalker opened 3 years ago

lukilukeskywalker commented 3 years ago

Hi, First of all, thanks for all the hard work that you have been putting on this library. The last days I have been trying to use this library but I have failed, as when the uC (ESP32) executes nav.doOutput(); it crashes. Maybe I have been doing something wrong or I haven't set the library properly. I have noticed that when I try to draw something, before executing nav.doOutput() , it does draw a single time the menu, and changes the styling. After that It doesn't ever enter in the if controlled by nav.changed(0) even when I do manipulate the encoder. I know that how I present events to the arduinomenu library is not standard, but I wanted to use the quadrature counter present in the ESP32. The events to the arduinomenu are presented in the checkEncoder() function, where it just checks if the counter has increased or has decreased, and creates an encoder UP or DOWN event in the Arduinomenu (RotaryEventIn::EventType::ROTARY_CCW | // up RotaryEventIn::EventType::ROTARY_CW)

Anyway here is the code: Pastebin Code And here is the exception decoded Pastebin Exception

krieg-geist commented 3 years ago

I have been having almost the exact same issue with an ESP8266. I have tried several combinations of different ESP Arduino framework and ArduinoMenu versions to no avail.