From 13a848ce63fb750fb6dd8b3f84175a8a64f164fa Mon Sep 17 00:00:00 2001 From: Per Lindgren <per.lindgren@ltu.se> Date: Thu, 11 Jun 2020 16:03:44 +0200 Subject: [PATCH] bluepill works --- .cargo/config | 4 ++-- README.md | 8 ++++++++ memory.x | 4 ++-- 3 files changed, 12 insertions(+), 4 deletions(-) diff --git a/.cargo/config b/.cargo/config index e83870c..5d98277 100644 --- a/.cargo/config +++ b/.cargo/config @@ -28,6 +28,6 @@ rustflags = [ [build] # Pick ONE of these compilation targets # target = "thumbv6m-none-eabi" # Cortex-M0 and Cortex-M0+ -# target = "thumbv7m-none-eabi" # Cortex-M3 +target = "thumbv7m-none-eabi" # Cortex-M3 # target = "thumbv7em-none-eabi" # Cortex-M4 and Cortex-M7 (no FPU) -target = "thumbv7em-none-eabihf" # Cortex-M4F and Cortex-M7F (with FPU) +# target = "thumbv7em-none-eabihf" # Cortex-M4F and Cortex-M7F (with FPU) diff --git a/README.md b/README.md index 293c092..4aa37cd 100644 --- a/README.md +++ b/README.md @@ -102,6 +102,12 @@ MEMORY $ cargo build ``` +## probe.rs, cargo-flash and friends + +``` console +$ cargo flash --example hello --release --chip STM32F103C8 --log debug +``` + ## VS Code This template includes launch configurations for debugging CortexM programs with Visual Studio Code located in the `.vscode/` directory. @@ -133,3 +139,5 @@ to intervene to uphold that code of conduct. [CoC]: https://www.rust-lang.org/policies/code-of-conduct [team]: https://github.com/rust-embedded/wg#the-cortex-m-team + + diff --git a/memory.x b/memory.x index b271f22..7367b27 100644 --- a/memory.x +++ b/memory.x @@ -3,8 +3,8 @@ MEMORY /* NOTE 1 K = 1 KiBi = 1024 bytes */ /* TODO Adjust these memory regions to match your device memory layout */ /* These values correspond to the LM3S6965, one of the few devices QEMU can emulate */ - FLASH : ORIGIN = 0x00000000, LENGTH = 256K - RAM : ORIGIN = 0x20000000, LENGTH = 64K + FLASH : ORIGIN = 0x08000000, LENGTH = 32K + RAM : ORIGIN = 0x20000000, LENGTH = 16K } /* This is where the call stack will be allocated. */ -- GitLab