Marus / cortex-debug

Visual Studio Code extension for enhancing debug capabilities for Cortex-M Microcontrollers
MIT License
1.01k stars 240 forks source link

pyocd, issue with command-line options #254

Closed haneefdm closed 4 years ago

haneefdm commented 4 years ago

Currently, we start pyocd with the option --reset-break. This causes a failure for my device (PSoC62).

If runToMain is true, it works normally near as I can tell. Otherwise, while it does stop at the reset vector but if I do a continue and a pause, I get no/bogus stack trace, no threads, etc.

But if I remove the --reset-break arg, everything works like normal whether runToMain is true or false. This puzzled me for a long long time until I found the culprit arg.

I recommend removing this default command-line argument as it has been deprecated and causes problems. I think the new behavior naturally does the break on reset. Also, there is no way to undo the default args that I know of -- even with serverArgs

I already made the changes and can make a PR soon

haneefdm commented 4 years ago

I made a PR #256 and this option has been removed as a default option. You can always add it if needed using the serverArgs option.