Skip to content
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

Fix openocd command in Verify Installation section. #268

Closed
wants to merge 1 commit into from

Conversation

airelil
Copy link

@airelil airelil commented Oct 9, 2020

For the recent STM32F303VCT6, it should refer interface/stlink-v2-1.cfg.
Same as in https://github.com/rust-embedded/cortex-m-quickstart/blob/be44af69cc91e2ff5b75f400e09488cba44e9f59/openocd.cfg#L7
Otherwise, using the currently specified interface/stlink.cfg produces openocd error:

Error: open failed
in procedure 'init'
in procedure 'ocd_bouncer'

For recent STM32F303VCT6, it should refer interface/stlink-v2-1.cfg.
Same as in https://github.com/rust-embedded/cortex-m-quickstart/blob/be44af69cc91e2ff5b75f400e09488cba44e9f59/openocd.cfg#L7
Otherwise, using the currently specified interface/stlink.cfg produces openocd error:
```
Error: open failed
in procedure 'init'
in procedure 'ocd_bouncer'
```
@airelil airelil requested a review from a team as a code owner October 9, 2020 20:41
@rust-highfive
Copy link

Thanks for the pull request, and welcome! The Rust team is excited to review your changes, and you should hear from @jamesmunns (or someone else) soon.

If any changes to this PR are deemed necessary, please add them as extra commits. This ensures that the reviewer can see what has changed since they last reviewed the code. Due to the way GitHub handles out-of-date commits, this should also make it reasonably obvious what issues have or haven't been addressed. Large or tricky changes may require several passes of review and changes.

Please see the contribution instructions for more information.

@rust-highfive rust-highfive added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-resources labels Oct 9, 2020
@adamgreig
Copy link
Member

Thanks for this PR! I think this is related to #263. In the latest version of openocd, you should use the new stlink.cfg, which works for all ST-links. However, in openocd 0.10, which is the most recent released version (albeit a few years old), there are still the -v2 etc scripts.

Perhaps the book should be updated to suggest trying out the -v2, especially since lots of people are hitting this issue, but it's not right to only suggest it, since users on the latest versions of openocd (and users in the future) will need what's currently in the book.

@airelil
Copy link
Author

airelil commented Oct 10, 2020

Fair enough. Thank's for pointing me to #268. It's just from a consistency point of view, openocd version 0.10 is still what user ends up with by following the installation instructions for Linux. Will it be a different version on Mac or Windows platform? Notice also that ver 0.10 is presented in the example of expected output from openocd and st*v2 scripts are referred from openocd.cfg coming with the "cortex-m-quickstart" template recommended by the book in the next section.

@airelil airelil closed this Oct 10, 2020
bors bot added a commit that referenced this pull request Feb 17, 2021
284: Add note about using more recent openocd interface file. Closes #277 and #263 r=eldruin a=adamgreig

This is a long-standing issue thanks to openocd's confusing rename of this interface file and not having a release for many years (see also #283 and #268).

Co-authored-by: Adam Greig <adam@adamgreig.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-resources
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants