In embedded Rust, .cargo/config.toml centralizes settings that make builds target the right hardware and run through the chosen flashing or debugging tool. It avoids repeating long, error-prone arguments on each Cargo command. section 3.2.3
[target.thumbv7m-none-eabi] runner = "gdb-multiarch -q -x openocd.gdb" rustflags = [ "-C", "link-arg=-Tlink.x", ] [build] target = "thumbv7m-none-eabi"
This Cortex-M3 configuration selects the target, sets a GDB/OpenOCD runner, and passes a linker script to rustc. Replace the runner with `probe-rs run` to use probe-rs instead. section 3.2.3
Choose a target triple that matches the microcontroller. The linker script must also describe the device’s memory layout; that layout is specified separately in memory.x and should match the hardware. section 2.4.3 section 3.2.3
