Adafruit Grand Central debugging with atmel-ice

Oh yes this is perfect, this proves that the OpenOCD command is correct for connecting to the chip. You can close that program again with Ctrl+C.

Now you can add this to your platformio.ini

debug_tool = custom
debug_server =
  $PROJECT_PACKAGES_DIR/tool-openocd/bin/openocd.exe
  -s
  $PROJECT_PACKAGES_DIR/tool-openocd/scripts
  -f 
  interface\jlink.cfg
  -c
  "transport select swd"
  -c
  "set CHIPNAME at91samd51p20"
  -f
  target\atsame5x.cfg

and then check if debugging works (Run → Start Debugging in VSCode)

With JLink and SAMD(51/21) chips there might be some quirks though where you have to restart the debugging, due to… either the bootloader, USB initialization or MCU restart: JLink ‘Stopping in Setup()' - #11 by maxgerhardt and related Problems starting debug session with jlink on feather M0 - #11 by prototypicalpro

In any case if the debug_server directives work, debugging should at least stop one time at some breakpoint regardless.