-
Notifications
You must be signed in to change notification settings - Fork 549
Update docs #189
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
Update docs #189
Conversation
Thanks for the pull request, and welcome! The Rust team is excited to review your changes, and you should hear from @ryankurte (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. |
@@ -104,7 +104,7 @@ Breakpoint 1, main () at src/06-hello-world/src/main.rs:10 | |||
10 let mut itm = aux6::init(); | |||
``` | |||
|
|||
Note that there's a `.gdbinit` at the root of the Cargo project. It's pretty similar to the one we | |||
Note that there's a `openocd.gdb` at the root of the Cargo project. It's pretty similar to the one we |
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.
It looks like openocd.gdb
used to be named .gdbinit
, and this doc wasn't updated when the file name changed.
@@ -22,4 +22,6 @@ Recommended steps to wire this up: | |||
And that's it! You should be able to run all the programs you wrote in [section 11] without | |||
modification! Just make sure you open the right serial device / COM port. | |||
|
|||
**NOTE** If you are having trouble communicating with the bluetooth device, you may need to initialize USART1 with a lower baud rate. Lowering it from 115,200 bps to 9,600 bps might help, as described [here](https://github.com/rust-embedded/discovery/blob/master/src/11-usart/auxiliary/src/lib.rs#L31) | |||
|
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.
I was stuck on this step, and after some debugging, I discovered that the program was getting stuck on this line:
while usart1.isr.read().rxne().bit_is_clear() {}
(which can be seen in the solution file here: https://github.com/rust-embedded/discovery/blob/master/src/11-usart/my-solution.md)
After some exploration - and some help from a friend! - I discovered that it was due to the baud mismatch between the chip and the bluetooth module. Setting the baud rate to 9600.bps()
, as mentioned above, fixed the issue.
**NOTE**: If you are getting errors like `undefined debug reason 7 - target needs reset` on the OpenOCD GDB server, then you may need to try using `arm-none-eabi-gdb` instead of the `gdb` command, as described above. | ||
**NOTE**: If you are getting errors like `undefined debug reason 7 - target needs reset`, you can try running `monitor reset halt` as described [here](https://stackoverflow.com/questions/38994596/reason-7-target-needs-reset-unreliable-debugging-setup). | ||
|
||
**NOTE**: If the debugger is still not connecting to the OpenOCD server, then you may need to try using `arm-none-eabi-gdb` instead of the `gdb` command, as described above. |
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.
This is in response to this comment: ffeabc6#r34883585
My original note incorrectly conflated the undefined debug reason 7
output with my issue where I was using gdb
instead of arm-none-eabi-gdb
. This update clarifies the issues that may arise, and addresses them separately.
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.
Looks good to me.
bors r+ |
Build succeeded |
No description provided.