PlatformIO Community

Debugger stopped working in VSCode

I’ve been using PIO debugger in VSCode without issues for 2+ years but recently it stopped working. I am using VSCode 1.64.0 with PIO 5.2.4 on Windows 10 and I have disabled all VSCode extensions except for PIO and Microsoft C/C++. I am able to run “pio debug --interface=gdb -x .pioinit” and it starts fine stopping at the specified initial breakpoint. In addition, I am able to upload code using the same target board interface (stlink) without problems. So, I am pretty confident there is no issue with debugger connection to the target board.

When I try to start the debugger through any of the menu items I would see the debugger control button panel pop up briefly then disappears without any error messages. There doesn’t seem to be any attempt to connect to the target. So, I am hoping PIO experts can provide some guidance on how to resolve this problem. Any help would be greatly appreciated.

There seems to be a general issue now with PlatformIO and debugging in VSCode. I’ve opened about this but I cannot get a reproduction of the issue. I’m already at the lastest VSCode 1.64.0 version and have the newest PlatformIO extension and switched around the Microsoft C/C++ extension but it is still working.

Can you copy the VScode Help → About information and show a screenshot of your installed VSCode extensions with their exact versions?

What exactly is your target board and platformio.ini?

Could you share your platformio.ini?

Hi Ivan
i have the same problem (working on a old instalation upgradet with newest VS code and Platformio) but not on a new instalation (new Win10 and VS code + Platformio)
Please see

Please update the PlatformIO IDE extension to the latest version. Does it work now?

Yes, the debugger now starts up as expected. Thank you for the quick fix!