1 of 1 people found this helpful
Please make sure that in the "launch.json" file you have set the "debugServerPath" and "MIDebuggerPath" correctly. Please clarify the following:
- Are you using "mbed" or "make" in the preLaunchTask?
- Are you using openocd or pyocd as the server?
Please attach the "launch.json" and the "tasks.json" file along with the screenshot of the error so that we can get more insight on the error.
In tasks.json, I'm using mbed
In launch.json, the prelaunchTask is mbed.exe
debug server is pyocd-gdbserver.exe
Here is the error:
Logs from output and debug windows attached.
Dheeraj - any progress with the debugging? My guess is whatever is messing this up in VScode is likely the same thing messing up in MTB 2 when importing from Mbed. See my community post: Re: g++: Command not found and maybe you can work with Raktim to solve both issues.
Yes, but I don't know where to put the equivalent flag in the VSCode implementation if that is the same issue here.
Please add the flags in the field highlighted below:
"name": "C++ Launch",
"debugServerArgs": "-p 3333 -t cy8c6xx7",
Let me know if it works. I'm attaching my file for reference.