Being new to programming microcontrollers, I figured debugging would be similar to what it is in Microsoft Visual Studio where I could set breakpoints and watch windows on different variables...HA! I was very disappointed to learn on microcontrollers, you often need a piece of HARDWARE like an esp-32 prog board or other JTAG device. When I discovered this and contemplating whether or not to continue even trying to debug my code, a great person on the platformIO website pointed out to me that the newer esp-32 controllers, specifically the esp32-C3 and -S3 have built-in JTAG capability. My board is a WEMOS lolin esp32-C3 pico and sure as heck, it has it built in. Now, this is only on platformIO and a couple of other IDEs. I also learned the hard way, to get it to work, you need to update the driver on the JTAG Serial device in Windows Device Manager. See this post:
Anyway, if this helps anybody...I'd like to pay it forward. If you have specific questions, I'd be glad to help if I can.
Fish