New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
SWO support is not being fully enabled in pyOCD #646
Comments
Thanks for reporting this. Not sure when that was added. We did not need that before. If SWO is enabled, we added the following
The variables you see with Note that we split the
I don't want to change any more code in the extension than I have to. Since I don't have a good board to try this out, I have to trust you for the change, but I will be happy to make that change. |
I think before, If we did not set it to raw, we got already parsed results so, it was not standard (pre-parsed) SWO packets. We need the raw byte stream. |
Yes, it seems to work both ways. No idea if it changed at some point, the flag was introduced with the initial SWO support in pyOCD. It sounds like it's supposed to be needed to enable SWO. I don't get any extra output in the pyOCD terminal. |
Yes it was there originally, but when tested it, it did not require it. Now it looks like we need both |
pyocd/pyOCD#1014 also kind of implies that the flag should be used with the raw output. Maybe it worked before without it as a happy little accident. |
They are initialiing a bunch of stuff and so are we. These are the GDB macros that are executed
This stuff predates me. These macros are in the gdbsupport.init file in /support directory. I don't think the first four lines are needed because it will trample on what pyOCD is doing. In fact, maybe none of it is needed except for the portmasks. You can probably edit that file in the install dir. and experiment. Those macros also use hard-coded addresses for TPIU/DWTetc. and with more recent MCU, they are no longer at ARM specified default addresses for some devices. You can make a copy of the file and load it in your All of this is if you have the time or inclination to help. It will be much appreciated. |
Hm, yeah I noticed that TPIU/ITM configuration is a bit of a problem. I guess in an ideal world, the debug server would know all device specific details and offer some high-level interface to configure TPIU/ITM, right? I wonder if it's worth the effort to work towards that. |
The original issue should be fixed in 1.5.0 |
When I try to enable SWO console output with pyOCD, I don't get any output. My configurations looks like this:
When I add
-Oenable_swv=1
toserverArgs
, it starts working. I think this should be added when SWO is configured.The text was updated successfully, but these errors were encountered: