Add bootloader to CI
This commit is contained in:
6
examples/boot/nrf/.cargo/config.toml
Normal file
6
examples/boot/nrf/.cargo/config.toml
Normal file
@ -0,0 +1,6 @@
|
||||
[target.'cfg(all(target_arch = "arm", target_os = "none"))']
|
||||
# replace nRF82840_xxAA with your chip as listed in `probe-run --list-chips`
|
||||
runner = "probe-run --chip nRF52840_xxAA"
|
||||
|
||||
[build]
|
||||
target = "thumbv7em-none-eabi"
|
@ -6,7 +6,7 @@ version = "0.1.0"
|
||||
|
||||
[dependencies]
|
||||
embassy = { version = "0.1.0", path = "../../../embassy", features = ["nightly"] }
|
||||
embassy-nrf = { version = "0.1.0", path = "../../../embassy-nrf", features = ["time-driver-rtc1", "gpiote", "nightly"] }
|
||||
embassy-nrf = { version = "0.1.0", path = "../../../embassy-nrf", features = ["time-driver-rtc1", "gpiote", "nightly", "nrf52840"] }
|
||||
embassy-boot-nrf = { version = "0.1.0", path = "../../../embassy-boot/nrf" }
|
||||
embassy-traits = { version = "0.1.0", path = "../../../embassy-traits" }
|
||||
|
||||
|
@ -17,15 +17,15 @@ application.
|
||||
|
||||
```
|
||||
# Flash bootloader
|
||||
cargo flash --manifest-path ../../embassy-boot/nrf/Cargo.toml --release --features embassy-nrf/nrf52840 --chip nRF52840_xxAA
|
||||
cargo flash --manifest-path ../../../embassy-boot/nrf/Cargo.toml --features embassy-nrf/nrf52840 --release --chip nRF52840_xxAA
|
||||
# Build 'b'
|
||||
cargo build --release --features embassy-nrf/nrf52840 --bin b
|
||||
cargo build --release --bin b
|
||||
# Generate binary for 'b'
|
||||
cargo objcopy --release --features embassy-nrf/nrf52840 --bin b -- -O binary b.bin
|
||||
cargo objcopy --release --bin b -- -O binary b.bin
|
||||
```
|
||||
|
||||
# Flash `a` (which includes b.bin)
|
||||
|
||||
```
|
||||
cargo flash --release --features embassy-nrf/nrf52840 --bin a --chip nRF52840_xxAA
|
||||
cargo flash --release --bin a --chip nRF52840_xxAA
|
||||
```
|
||||
|
Reference in New Issue
Block a user