-
Notifications
You must be signed in to change notification settings - Fork 490
Add picoprobe cmsis-dap support #1198
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
Add picoprobe cmsis-dap support #1198
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks, this is great!
One additional change needs to be made, though, to get the release packaged version working right. You'll need to add a new set of sed
macros to fix the platform.txt rules paths:
arduino-pico/package/build_boards_manager_package.sh
Lines 112 to 117 in 7afcec8
sed 's/^tools.picoprobe.cmd=.*//g' | \ | |
sed 's/^#tools.picoprobe.cmd=/tools.picoprobe.cmd=/g' | \ | |
sed 's/^tools.picotool.cmd=.*//g' | \ | |
sed 's/^#tools.picotool.cmd=/tools.picotool.cmd=/g' | \ | |
sed 's/^tools.picodebug.cmd=.*//g' | \ | |
sed 's/^#tools.picodebug.cmd=/tools.picodebug.cmd=/g' | \ |
Also, would it make sense to add the adapter speed 5000
to the TCL
file you added? That way it always takes effect?
Very interesting. I also recently had problems when I flashed the new Picoprobe firmware and suddenly I could not upload to my target RP2040 again. Had to search for an older release to get up an running again. I will also need to pull these changes into platform-raspberrypi and state / document very clearly that the Picoprobe upload now has two possible different configurations ( |
Would it make sense to just call it |
sorry, I was busy last few days, and couldn't make changes as request. Thanks for doing that. For the tcl script, yes, I think we should add the speed selection to scrip file. However, to be honest, I haven't tried and run that script yet. I am not so sure on the syntax, please free feel to add it. PS: the new pico debug probe from https://www.raspberrypi.com/products/debug-probe/ is based on the cmsis dap version aka this PR. So @earlephilhower may be we should just rename this to pi-debug-probe or something. I guess the amount of user that use this ready-to-use probe will increase by the time. |
No worries about the package changes, it's not something you'd know unless you delved deep into the guts of the core. Why didn't they go with USB-C for the connector on the new board? 😞 I'm sure they had their reasons, but it's a pain now with everything else on USB-C. The board runs the Picoprobe firmware unmodified, AFAICT, so I think the name should still be I can try flashing a new board to the CMSISDAP FW and see if it's just a matter of adding the |
Just did a quick check using the upload CMSIS command and the TCL script to start OpenOCD from the CLI (w/ #1218 added) and all seems good. Naming, we'll see if people complain :), but for now I think we're good to go. |
yeah, it is a bit weird for no USB-C in 2023 board. I am glad we wrapped this up. |
picoprobe have switched to use CMSIS DAP protocol in latest release
Therefore for new picoprobe implementation, openocd config now must be changes from
interface/picoprobe.cfg
(custom protocol) to more standard cmsis-dap protocolinterface/cmsis-dap.cfg
.From latest getting started with pico
Note: even though the getting started doc does not mention, but I found that
adapter speed 5000
is required, otherwise we will getError: CMSIS-DAP command CMD_DAP_SWJ_CLOCK failed
. Check out raspberrypi/openocd#78 for detail.With correct speed (as part of upload command), it works well and seem to be more reliably than the previous picoprobe implementation. Menu with PR chagnes