Rust challenge 52/100 - cross compiling for cortex-m3 machine lm3s6965evb and running on QEMU
Table of content
What is this
The rules of the game are explained in my original. Today I would like to tip my toe into some embedded programming.
52nd Challenge
Challenge
I will start off with some QEMU emulation. Challenge today is get the example up and running.
Solution
Following step for setup the tutorial on my macos was a success. The turoial is very well explained.
See github for the generated example (generated using cargo generate
.
Most imporant steps in summary:
cargo generate --git https://github.com/rust-embedded/cortex-m-quickstart
- start with debugging :
qemu-system-arm -cpu cortex-m3 -machine lm3s6965evb -nographic -semihosting-config enable=on,target=native -gdb tcp::3333 -S -kernel target/thumbv7m-none-eabi/debug/examples/hello
- connect to debugging session from second shell :
gdb -q target/thumbv7m-none-eabi/debug/examples/hello
- running :
qemu-system-arm -cpu cortex-m3 -machine lm3s6965evb enable=on,target=native -kernel target/thumbv7m-none-eabi/debug/examples/hello