arduino-libraries / NTPClient

Connect to a NTP server
551 stars 375 forks source link

Guru Meditation Error #107

Open workpage2 opened 4 years ago

workpage2 commented 4 years ago

I have a problem. My esp32 reboots while trying to read the time. The standard example works without errors. The call from setup in my program works without problems. But in loop I have an error. I use many network protocols in the program. Websocket, mqtt, webserver ... Any thoughts.

Guru Meditation Error: Core 1 panic'ed (LoadProhibited). Exception was unhandled. Core 1 register dump: PC : 0x400df154 PS : 0x00060630 A0 : 0x800df17c A1 : 0x3ffb1ea0
A2 : 0x3ffc1810 A3 : 0x3ffc1830 A4 : 0x00000030 A5 : 0x00006640
A6 : 0x00060420 A7 : 0x00000000 A8 : 0x00000081 A9 : 0x0000004e
A10 : 0x74732e00 A11 : 0x722e326d A12 : 0x00000030 A13 : 0x3ffc1860
A14 : 0x3ffc3f3c A15 : 0x00000003 SAR : 0x0000000a EXCCAUSE: 0x0000001c
EXCVADDR: 0x000000b9 LBEG : 0x4000c46c LEND : 0x4000c477 LCOUNT : 0x00000000

Backtrace: 0x400df154:0x3ffb1ea0 0x400df179:0x3ffb1ec0 0x400df24c:0x3ffb1ee0 0x400d1c7a:0x3ffb1f00 0x400d6e75:0x3ffb1f60 0x400e3de9:0x3ffb1fb0 0x40088b7d:0x3ffb1fd0

Rebooting...

jPerotto commented 3 years ago

Hi Bro, i'm have a similar problem. But, here is my exceptio decoder: I use the Arduino framework with version 1.0.4.

Decoding stack results 0x40093334: invoke_abort at /home/runner/work/esp32-arduino-lib-builder/esp32-arduino-lib-builder/esp-idf/components/esp32/panic.c line 155 0x40093565: abort at /home/runner/work/esp32-arduino-lib-builder/esp32-arduino-lib-builder/esp-idf/components/esp32/panic.c line 170 0x401eec83: cxxabiv1::terminate(void ()()) at /builds/idf/crosstool-NG/.build/src/gcc-5.2.0/libstdc++-v3/libsupc++/eh_terminate.cc line 47 0x401eecca: std::terminate() at /builds/idf/crosstool-NG/.build/src/gcc-5.2.0/libstdc++-v3/libsupc++/eh_terminate.cc line 57 0x401ee205: cxxabiv1::cxa_allocate_exception(std::size_t) at /builds/idf/crosstool-NG/.build/src/gcc-5.2.0/libstdc++-v3/libsupc++/eh_alloc.cc line 268 0x401edf88: operator new(unsigned int) at /builds/idf/crosstool-NG/.build/src/gcc-5.2.0/libstdc++-v3/libsupc++/new_op.cc line 54 0x401edf4d: operator new[](unsigned int) at /builds/idf/crosstool-NG/.build/src/gcc-5.2.0/libstdc++-v3/libsupc++/new_opv.cc line 32 0x400ffadb: WiFiUDP::parsePacket() at /home/perotto/.arduino15/packages/esp32/hardware/esp32/1.0.4/libraries/WiFi/src/WiFiUdp.cpp line 210 0x40104fc5: NTPClient::forceUpdate() at /home/perotto/Arduino/libraries/NTPClient/NTPClient.cpp line 75 0x40105044: NTPClient::update() at /home/perotto/Arduino/libraries/NTPClient/NTPClient.cpp line 99 0x400f0395: processNTP() at /home/perotto/Documentos/GitHub/STU-GW/taskWiFi.ino line 373 0x400f37f5: doWiFiTask(void) at /home/perotto/Documentos/GitHub/STU-GW/taskWiFi.ino line 52 0x4008f7f5: vPortTaskWrapper at /home/runner/work/esp32-arduino-lib-builder/esp32-arduino-lib-builder/esp-idf/components/freertos/port.c line 143

I'm parsing and found a buffer in int WiFiUDP::parsePacket() with size char * buf = new char[1460];

see topic

https://github.com/espressif/arduino-esp32/issues/4104

jPerotto commented 3 years ago

See other issue

https://github.com/espressif/arduino-esp32/issues/2212#issuecomment-781128662