probe-rs is a Rust library and toolset for communicating with debug probes and controlling embedded targets. It supports flashing, reset and run control, debug transport, and RTT capture. Higher-level tools such as cargo-flash and cargo-embed build on this foundation. section 2.6.1 section 6.2.4
A Cargo runner lets cargo run flash and start firmware on the target. Configure the runner in .cargo/config.toml with the target architecture and chip name. Use probe-rs chip list to find recognized chip identifiers. section 2.6.1 section 6.3.4
[target.thumbv7m-none-eabi] runner = "probe-rs run --chip STM32F103C8Tx"
This runner configuration selects the thumbv7m target and an STM32F103C8Tx chip for a Blue Pill board. section 2.6.1
Alternatively, invoke probe-rs run directly with a chip identifier and a built ELF path. It flashes the binary and streams RTT output to the terminal. For defmt logs, it also uses ELF metadata to decode the output. section 6.2.4 section 6.3.4
cargo install probe-rs-tools probe-rs run --chip STM32F103C8T6 target/thumbv7m-none-eabi/release/app
Install the tools, then run a built application on the specified chip. section 6.2.4
RTT output is read from a target RAM buffer through the debug probe while firmware runs. For a one-off command, probe-rs run keeps the chip and ELF path explicit. For more involved settings, cargo-embed stores configuration in Embed.toml and can also provide a GDB server. cargo-flash is a simpler choice when live logging and debugging are not needed. section 6.2.4 section 2.6.1
Run firmware on a Blue Pill
Set up the app template and install the thumbv7m-none-eabi Rust target. In .cargo/config.toml, select that build target and set the runner chip to STM32F103C8. With the project's memory map in place, cargo run --release --bin phoenix builds and runs the example, which prints a message using defmt. section 2.6.4
