Notes about Playing with the IDE 2 debugger,
For the fun of it, I thought I would try out one of the new features of the Arduino IDE that comes with IDE2, which is the debugger. I had not done so up until now as the Teensy boards do not support hardware debugging.
First issue: Finding boards to try this with. I looked at the Arduino documentation for this:
https://docs.arduino.cc/software/ide-v2/tutorials/ide-v2-debugger which I found very incomplete as it showed
only three categories of boards or ways to support boards (Direct USB, Segger J-Link, Atmel-ICE), none of which I have.
M0/M4 boards:
Direct USB, they showed only Arduino Zero - which I don't have, thought about ordering one, but at $50, sorry ...
Segger J-Link/Atmel Ice - Don't have, and if you don't qualify for Segger EDU version, their base unit is something like $500,
The EDU unit:
https://www.adafruit.com/product/3571 is about $60
But when I posted up on Arduino forum (
https://forum.arduino.cc/t/adding-debug-support-to-a-non-arm-eabi-board-type/1138076)
@PerT mentioned that he is using one of these:
https://www.tindie.com/products/ataradov/cmsis-dap-compliant-swd-debugger/
which at $12 is a little more reasonable

So I ordered one, which is now waiting for me in town in my mailbox, but while waiting, the
Tindie page mentioned, using an RPI Pico for this, and use the code or image up at:
https://github.com/ataradov/free-dap
Since I had 3 PICO boards sitting in a box, decided to try this. It works.
First up I tried the Arduino MKRZero - I needed to solder some wires onto the SWD pins on the bottom, and then jumpered it to the appropriate pins on the PICO.
it Worked

was able to start playing. Curiosity got me, as the same little box that I had the MKRZero in I had a couple of Adafruit M0 and M4 boards in, so tried those
and found that they did not enable the debug button, we were able to get the M0 working by adding the debug section to the platform.txt and update a few things in
their files to match the Arduino and the button was enabled and it worked on M0... We posted and created issue up on Adafruit and one of their contributors took it from there.
Yesterday he fixed it and Last night they integrated in a fix.

Part of it was they needed to switch from OpenOCD version 0.9. to 0.11.
Note: The Adafruit developer recommend another CMIS-DAP that Adafruit sells for $12:
https://www.adafruit.com/product/5699
The firmware for it is up at:
https://github.com/raspberrypi/picoprobe and I believe it can be used on the PICO board. I may try it soon.
ESP32 boards:
I noticed when playing with ESP32 boards that the debug button was enabled, so I have tried with a few different boards. Had some luck with a few of them, but...
Like the ESP32-S2 board, failed to launch it.
Likewise I tried a Micromod ESP32 and it failed the same way.
ESP32-C3 - was curious about these as they are a risc-v (not arm) board. The debugger actually comes up:

Not sure how well it works yet. Things like stepping on this board appears to fail. But I have an oddball clone of the ESP32-c3, I have a couple standard ones
waiting for me in my mailbox... Will hopefully try it out on those and see how it works.
RPI2040
I believe this is supposed to work. I tried hooking up with the Micromod RPI2040, but it has been awhile since I played with this and forgot how to program it
using the Arduino IDE... Will play some more.
That is all I have tried so far. May play around with a few others or go on to the next diversions. But this has been interesting.