2021-01-22 14:15:11 +00:00
|
|
|
[target.'cfg(all(target_arch = "arm", target_os = "none"))']
|
|
|
|
# (..)
|
|
|
|
rustflags = [
|
|
|
|
"-C", "linker=flip-link", # adds stack overflow protection
|
2021-04-08 12:16:26 +00:00
|
|
|
"-C", "link-arg=-Tdefmt.x", # defmt support
|
2021-01-22 14:15:11 +00:00
|
|
|
# (..)
|
|
|
|
]
|
|
|
|
|
2020-08-24 09:59:10 +00:00
|
|
|
[target.thumbv7em-none-eabihf]
|
2021-04-19 09:56:28 +00:00
|
|
|
# set custom cargo runner to flash & run on embedded target when we call `cargo run`
|
|
|
|
# for more information, check out https://github.com/knurling-rs/probe-run
|
2020-08-17 08:58:10 +00:00
|
|
|
runner = "probe-run --chip nRF52840_xxAA"
|
2020-06-09 09:52:27 +00:00
|
|
|
rustflags = [
|
|
|
|
"-C", "link-arg=-Tlink.x",
|
|
|
|
]
|
|
|
|
|
|
|
|
[build]
|
2021-04-19 09:21:21 +00:00
|
|
|
# cross-compile to this target
|
2020-08-24 09:59:10 +00:00
|
|
|
target = "thumbv7em-none-eabihf" # = ARM Cortex-M4
|