-
Notifications
You must be signed in to change notification settings - Fork 45
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
Advanced course - instructions for starting VSCode do not make sense #185
Comments
Secondly, the advanced/firmware/.vscode directory appears to me missing its launch.json file, so (cross) debugging and running on the Nordic target doesn't work at all for me... I also found I needed to download the Cortex-Debug extension for VSCode, and then tell it to use "gdb-multiarch" as its gdbPath before anything would work... |
With Cortex-Debug, gdb-multiarch, and a self-written launch.json file, it sort-of works now... Running a program, setting breakpoints and single-stepping all seems to work OK. But... display of variable values does not work. (If I hover the mouse pointer over the name of a variable, then I get a little empty, blank box...) Also, the output from the various "log::info!()" macros seems to go no-where... at least no-where that I can see in any of the VSCode windows. Have I done something wrong? |
For what it's worth, I am running VSCode 1.62.3 on Ubuntu 21.10, which is itself running in a Parallels VM on top of MacOS. |
Ah, yeah, that's somewhat confusing. The second part of the sentence shouldn't be needed as the right directory is already opened though, so I've removed it in #186.
That is because all firmware binaries are compiled with |
Got it... debug=2 seems to do the trick for watching local variables. Perhaps that level should be the default for the course material? |
So... what's going on with the "log::info!()" output? |
I tried again using "defmt::log!()" and same result - no sign of the output in any of the VSCode windows... |
Logging uses RTT, and the configured Cargo runner, |
Ah... so "cargo run" (on the command-line) invokes "probe-run", but VSCode uses the Cortex-Debug extension, which uses openocd, right? If that's right, then I will look at the openocd manual to see if I can get it to listen for RTT. |
Some discussion here: Marus/cortex-debug#456 |
In src/hello-world.md, it says to "open the src/bin/hello.rs file from the advanced/apps folder" but there is no "apps" folder below "advanced"
Should that be "advanced/firmware" instead?
The text was updated successfully, but these errors were encountered: