I don’t know if this question is a duplicate, but I am having issues trying to set the CONFIG_ESP_SYSTEM_PANIC_HALT option in my build_flags. When I tried to run my code here:
#ifdef CONFIG_ESP_SYSTEM_PANIC_HALT
#warning "using CONFIG_ESP_SYSTEM_PANIC_HALT option"
#endif
#ifdef CONFIG_ESP_SYSTEM_PANIC_REBOOT
#warning "using CONFIG_ESP_SYSTEM_PANIC_REBOOT option"
#endif
Only the first warning was printed. But when I encountered an abort() statement, the board printed the backtrace and rebooted immediately. Is there a problem with how I am setting the config?
Here is my platformio.ini file:
[env]
platform = espressif32
board = esp32doit-devkit-v1
monitor_raw = yes
monitor_speed = 115200
framework = arduino
build_flags =
-DCORE_DEBUG_LEVEL=3
-DCONFIG_ESP_SYSTEM_PANIC_HALT=y
-DCONFIG_ESP_SYSTEM_PANIC_REBOOT=n
-DCONFIG_FREERTOS_VTASKLIST_INCLUDE_COREID
build_unflags =
-DCONFIG_ESP_SYSTEM_PANIC_REBOOT
// Other envs