Libncurses5 is missing per default on recent distros, known per Problem with esp32 debug for Ubuntu. (undefined symbol: _Py_ZeroStruct) - #13 by maxgerhardt.
That is not good - you really want to make sure you’re using the 5.x core. Follow the given link there to try to remove other installations of PlatformIO from the system. You usually only want the PIO version that is installed with the VSCode PIO extension (and update PATH
to that one) and not any you install via pip
system-wide (becauses PlatformIO’s python packet requirements might get in the way – the PIO extension installs it in a nice isolated pyenv).
Your debug device is a USB device, not a tty port. Remote that line. But it shouldn’t actually have influence anything. The main culprit is that OpenOCD couldn’t find the device.
Are you sure that’s the right way? Maybe you selected a wrong debug_tool
and a different one would use the right .cfg
with the USB device you actuall have.
Remember that you can decode these exceptions better with monitor_filter and build_type.
; enable exception decoding when seen on the serial
monitor_filters = esp32_exception_decoder
; force debug mode during normal build & upload (makes backtrace symbols available)
build_type = debug