euro-yesman: update flasher configuration

wip/yesman
Katharina Fey 3 years ago
parent 3f2488eec2
commit 6dcf150b1f
Signed by: kookie
GPG Key ID: 90734A9E619C8A6C
  1. 10
      hardware/euro-yesman/.cargo/config
  2. 6
      hardware/euro-yesman/default.nix
  3. 3
      hardware/euro-yesman/flash.sh
  4. 6
      hardware/euro-yesman/openocd.cfg
  5. 19
      hardware/euro-yesman/openocd.gdb
  6. 9
      hardware/euro-yesman/shell.nix

@ -1,6 +1,8 @@
[target.thumbv7m-none-eabi]
[target.'cfg(all(target_arch = "arm", target_os = "none"))']
runner = "arm-none-eabi-gdb -tui -q -x openocd.gdb"
rustflags = [ "-C", "link-arg=-Tlink.x" ]
[build]
# Always compile for the instruction set of the STM32F1
target = "thumbv7m-none-eabi"
# use the Tlink.x scrip from the cortex-m-rt crate
rustflags = [ "-C", "link-arg=-Tlink.x"]

@ -1,6 +0,0 @@
with (import <nixpkgs> {});
stdenv.mkDerivation {
name = "bad-rust-env";
buildInputs = with pkgs; [ rustup clangStdenv cargo-flash openocd ];
}

@ -0,0 +1,6 @@
# This is required to make it work with my fake stm32
set CPUTAPID 0x2ba01477
source [find interface/stlink.cfg]
source [find target/stm32f1x.cfg]

@ -0,0 +1,19 @@
target remote :3333
# print demangled symbols
set print asm-demangle on
# detect unhandled exceptions, hard faults and panics
break DefaultHandler
break UserHardFault
break rust_begin_unwind
# *try* to stop at the user entry point (it might be gone due to inlining)
break main
monitor arm semihosting enable
load
# start the process but immediately halt the processor
stepi

@ -0,0 +1,9 @@
with (import <nixpkgs> {});
stdenv.mkDerivation {
name = "bad-rust-env";
buildInputs = with pkgs; [
rustup clangStdenv gcc-arm-embedded
cargo-flash cargo-binutils openocd
];
}
Loading…
Cancel
Save