Closed valeros closed 6 years ago
Could you please attach the elf file, GDB remote log, and openocd log with increased log level (-d 3
)? Thanks.
Ok, thanks. I've tried reproducing this, looks like there are three issues:
uxTopUsedPriority
symbol, which must be linked in via an LD flag (source). Maybe the flag is missing in Arduino platform.txt.mon reset
doesn't work reliably if 240MHz CPU frequency is selected. Since we have lowered the default in IDF to 160MHz, I hadn't noticed this previously. Hopefully this is easy to fix...The 2nd point (mon reset issue) has now been fixed, merge pending. The 3rd issue has been fixed in ESP-IDF and will propagate to Arduino next time library update happens. The 1st point must still be added to Arduino build script, i think.
Perhaps already solved in ESP-IDF, but I am using the Windows Sloeber-Arduino plugin.
I solved this problem in Eclipse, by doing 2 things:
1: Setting the parameters in Eclipse->DebugAs->DebugConfiguration->GdbHardwareDebuging->Startup as follows: monitor reset halt x $a1=0 thb loop thr 0 // This was my lucky guess. Mind you: your application should reside in the APP-CPU. c
2: Include file FreeRTOS-openocd.c the project...
Using gdb also works; open a command shell and enter: xtensa-esp32-elf-gdb.exe -x application.elf an error message is generated: esp32: target state: halted 0x0: 0x00000000 Thread ID 0 not known. Type ctrl-C and then you are able to enter GDB-commands i.e. set breakpoints , single step etc....
Hi! I'm having a strange problem with debugging a simple example from Arduino IDE, whereas "Hello World" example from ESP-IDF can be debugged perfectly. Hardware: FT2232H + esp32 dev board connected via JTAG.
When I'm trying to debug a simple "WiFiScan" sketch from Arduino in GDB I see either this GDB log with next openOCD log (looks like MCU stuck in ResetVector) or this one and this openOCD log with a strange thread number.
gdbinit it the same for both cases:
Am I missing something? Any advice and suggestions will be greatly appreciated!