Using ESP-Prog debugger with PIO

I’m following one of the many blogs about how to use the ESP-Prog debugger board with an ESP32 board. Since I’m on Linux Mint 20, I’m having to read between the lines some.
First issue is I can’t upload a test sketch after it compiles successfully without removing the USB connector (/dev/ttyUSB0) while I’m uploading. Why is that?

Second issue is when I start debugging It brings up the normal debugging window, but then the continue, step-over, set into buttons appear and then disappear. When I look at the debug console I see the following:

undefinedpiogdb: error while loading shared libraries: libncurses.so.5: cannot open shared object file: No such file or directory
Not really sure where to go from here.

The debugger requirest hat some libraries are preinstalled on the system. You’re missing the ncurses lib.

Have you tried doing a sudo apt install libncurses5?

Per this it might also need a sudo apt-get install libncurses5-dev libncursesw5-dev.

Thanks, that got me past that error, but the next one was troubling. It’ missing a python2.7 lib, which is concerning on Linux Mint 20
undefinedpiogdb: error while loading shared libraries: libpython2.7.so.1.0: cannot open shared object file: No such file or directory

The GDB executables etc are built for the lower possible denominator, to support the widest range of linux machines. Recently, many Linux distributions have indeed stopped shipping with Python2.7 by default.

I’d suggest to try and sudo apt install python2.7 libpython2.7. This should not harm the OS – Python3 and Python2 can coexist.

Also see Problem with esp32 debug for Ubuntu. (undefined symbol: _Py_ZeroStruct) - #13 by maxgerhardt.

Thanks,

sudo apt install libpython2.7-dev

Got me past the error and the debugging has started. Now I just need to figure out how to use the debugger effectively.

AND it fixed the ability to upload the sketch without unplugging the USB serial cable hooked to the ESP-Prog