Well the base error is that PlatformIO doesn’t seem to be able to execute any commands from inside VSCode to the Jlink tools.
When I do “Start Debugging” in VSCode with the above
platformio.ini, I do get the JLink output, telling me it failed to start (since no JLink is connected of course)
And I do get the “Verbose Upload” JLink output as indicated above.
I’m not excluding antivirus to be a culprit if you get no output at all.
It seems to help in your setup though to specify explicit commands.
For uploading you can also try the
platform = teensy
board = teensy41
framework = arduino
upload_protocol = custom
upload.jlink file at the same level as the
platformio.ini with content
Then check “Verbose Upload” if the tool is invoked correctly and flashes correctly (docs).