ESP32-S3 Crashed and stuck - Didn't Restart

Amal@consyst
Posts: 3
Joined: Thu Aug 25, 2022 4:55 am

ESP32-S3 Crashed and stuck - Didn't Restart

Postby Amal@consyst » Thu Jul 25, 2024 4:25 am

  1.  
  2. static void setup2()
  3. {
  4.     Serial.println("Setup (runnning on 2nd core)");
  5. }
  6.  
  7.  
  8. static void loop2()
  9. {
  10.     HandleConfigButton();
  11.     HandleActivity();
  12.  
  13.     // To resolve core panic because of Watch Dog Timer not being reset
  14.     delay(1);
  15. }
  16.  
  17.  
  18.  
  19. // This is task running on the second core of ESP32
  20. void TaskOnCore2( void * pvParameters )
  21. {
  22.     Serial.print("Task running on core ");
  23.     Serial.println(xPortGetCoreID());
  24.  
  25.     // One time setup
  26.     setup2();
  27.     for (;;)
  28.     {
  29.         // Loop function
  30.         loop2();
  31.     }
  32. }
  33.  
  34.  
  35. TaskHandle_t HandleTaskOnCore2;
  36. void LaunchLoopOnSecondCore()
  37. {
  38.  
  39.     xTaskCreatePinnedToCore(
  40.                 TaskOnCore2,         /* Task function. */
  41.                 "TaskOnCore_2",      /* name of task. */
  42.                 10000,               /* Stack size of task */
  43.                 NULL,                /* parameter of the task */
  44.                 1,                   /* priority of the task */
  45.                 &HandleTaskOnCore2,  /* Task handle to keep track of created task */
  46.                 ESP32_SECOND_CORE);  /* pin task to second core */
  47.  
  48. }
  49.  
  50. void setup()
  51. {
  52.     Serial.begin(9600);
  53.     LaunchLoopOnSecondCore();
  54. }
  55.  
  56. void loop()
  57. {
  58.     HandleActivity();
  59. }
  60.  

Above given is a short version of the Arduino code I used in my ESP32-S3.
On some occasion I am getting a crash , but unlike any other crash this one is not restarting the Board itself - it is forever stuck at the crash.

Here is the crash Log:
Task running on core 0
Setup (runnning on 2nd core)Guru Meditation Error: Core 1 panic'ed (Unhandled debug exception).
Debug exception reason: Stack canary watchpoint triggered (ipc1)
Core 1 register dump:
PC : 0x4037db37 PS : 0x00060036 A0 : 0x8037c750 A1 : 0x3fcf1b10
A2 : 0x3fc94510 A3 : 0xb33fffff A4 : 0x0000cdcd A5 : 0x00060023
A6 : 0x00060023 A7 : 0x0000abab A8 : 0xb33fffff A9 : 0xffffffff
A10 : 0x00000000 A11 : 0x3fc94450 A12 : 0x7e140000 A13 : 0x08bb0000
A14 : 0x02c94510 A15 : 0x00ffffff SAR : 0x0000000e EXCCAUSE: 0x00000001
EXCVADDR: 0x00000000 LBEG : 0x00000000 LEND : 0x00000000 LCOUNT : 0x00000000


Backtrace: 0x4037db34:0x3fcf1b10 0x4037c74d:0x3fcf1b50 0x4037b02c:0x3fcf1b80 0x4037b022:0xa5a5a5a5 |<-CORRUPTED



ELF file SHA256: d451f74eeae971ec
I used ESP Exception decoder and found these :
PC: 0x4037db37EXCVADDR:
0x00000000
Decoding stack results

0x4037db34: xPortEnterCriticalTimeout at /Users/ficeto/Desktop/ESP32/ESP32S2/esp-idf public/components/esp_hw_support/include/soc/compare_set.h line 25

0x4037c74d: vTaskSwitchContext at /Users/ficeto/Desktop/ESP32/ESP32S2/esp-idf-public/components/freertos/port/xtensa/include/freertos/portmacro.h line 578

can someone please explain what is wrong.

Who is online

Users browsing this forum: No registered users and 246 guests