Did you see Error CMSIS-DAP command CMD_DAP_SWJ_CLOCK failed – Alan C. Assis where you have to add the adapter speed in the config file? (Likely C:\Users\<user>\.platformio\packages\tool-openocd-raspberrypi\share\openocd\scripts\interface\cmsis-dap.cfg
)
To my knowledge, due to issue Call to configure_debug_options() gone · Issue #4020 · platformio/platformio-core · GitHub, it prevents setting the adapter speed per this code, so you have to do that workaround now…