Can GNU MCU Eclipse be used to debug ESP32?

User avatar
i_am_mrp
Posts: 27
Joined: Thu Sep 28, 2017 9:14 am
Location: California

Can GNU MCU Eclipse be used to debug ESP32?

Postby i_am_mrp » Tue Dec 05, 2017 12:28 am

I am using Eclipse HW Debugging plugin with the Espressif ESP32 Wrover kit board.

So far, this combination is incredibly unstable (frequent Eclipse hangs or random GDB disconnects, etc..), so I am searching for alternatives or hints/configuration to make things more stable.

User avatar
iot-bits.com
Posts: 25
Joined: Wed Dec 21, 2016 6:14 am
Location: India
Contact:

Re: Can GNU MCU Eclipse be used to debug ESP32?

Postby iot-bits.com » Tue Dec 05, 2017 7:10 am

I noticed that manually resetting the ESP32 just before launching the debugger helps.
But it is not just Eclipse, same is the case with VisualGDB on Visual Studio.
Probably has something to do with lack of proper support for the reset line driving for ESP32?
- Pratik
:geek: Just another hobbyist and consultant

User avatar
i_am_mrp
Posts: 27
Joined: Thu Sep 28, 2017 9:14 am
Location: California

Re: Can GNU MCU Eclipse be used to debug ESP32?

Postby i_am_mrp » Tue Dec 05, 2017 9:02 pm

Thanks for the hint.

Yes, in general I have to power reset the ESP32 before I can debug again.

The ESP-IDF debugging documentation http://esp-idf.readthedocs.io/en/latest ... g-debugger suggests using:
mon reset halt
x $a1=0
The somewhat cryptic "x $a1=0" is described at: http://esp-idf.readthedocs.io/en/latest ... uirks.html as a way to force GDB to get new state from the target. I don't think it does and/or always works since we have to power reset nearly every time before OpenOCD can start and then debug again.

My stability issues deal with unexpected break/watch points being triggered in FreeRTOS code even though no breaks/watches were set in that code. Resuming debug execution (or single-step, step over, step into, step out of) all result in an approx a 10 second pause and then the debug session is disconnected.

Who is online

Users browsing this forum: No registered users and 77 guests