Skip to content

Commit 9de137b

Browse files
Merge pull request #183 from chocol4te/master
Upgrade rtfm-demo to RTIC and bump dependencies
2 parents ed8bf7f + 12d6c4b commit 9de137b

File tree

6 files changed

+19
-17
lines changed

6 files changed

+19
-17
lines changed

Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ members = [
55
"nrf52833-hal",
66
"nrf52840-hal",
77
"nrf9160-hal",
8-
"examples/rtfm-demo",
8+
"examples/rtic-demo",
99
"examples/spi-demo",
1010
"examples/twi-ssd1306",
1111
"examples/ecb-demo",
Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,14 @@
11
[package]
2-
name = "rtfm-demo"
2+
name = "rtic-demo"
33
version = "0.1.0"
44
authors = ["James Munns <[email protected]>"]
55
edition = "2018"
66
publish = false
77

88
[dependencies]
9-
cortex-m-rtfm = "0.4.3"
10-
panic-semihosting = "0.5.1"
11-
cortex-m-semihosting = "0.3.3"
9+
cortex-m-rtic = "0.5.3"
10+
panic-semihosting = "0.5.3"
11+
cortex-m-semihosting = "0.3.5"
1212

1313
[dependencies.nrf51-hal]
1414
path = "../../nrf51-hal"
Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
use panic_semihosting;
66

77
use cortex_m_semihosting::{debug, hprintln};
8-
use rtfm::app;
8+
use rtic::app;
99

1010
#[cfg(feature = "51")]
1111
use nrf51_hal as hal;
@@ -22,16 +22,18 @@ use nrf52840_hal as hal;
2222
#[app(device = crate::hal::pac)]
2323
const APP: () = {
2424
#[init]
25-
fn init() {
25+
fn init(_: init::Context) {
2626
hprintln!("init").unwrap();
2727
}
2828

2929
#[idle]
30-
fn idle() -> ! {
30+
fn idle(_: idle::Context) -> ! {
3131
hprintln!("idle").unwrap();
3232

3333
debug::exit(debug::EXIT_SUCCESS);
3434

35-
loop {}
35+
loop {
36+
continue;
37+
}
3638
}
3739
};

scripts/build.sh

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -18,14 +18,14 @@ cargo build --manifest-path nrf52833-hal/Cargo.toml
1818
echo Building nrf52840-hal...
1919
cargo build --manifest-path nrf52840-hal/Cargo.toml
2020

21-
echo Building examples/rtfm-demo...
22-
cargo build --manifest-path examples/rtfm-demo/Cargo.toml
23-
echo Building examples/rtfm-demo...
24-
cargo build --manifest-path examples/rtfm-demo/Cargo.toml --no-default-features --features="51" --target thumbv6m-none-eabi
25-
echo Building examples/rtfm-demo...
26-
cargo build --manifest-path examples/rtfm-demo/Cargo.toml --no-default-features --features="52810" --target thumbv7em-none-eabi
27-
echo Building examples/rtfm-demo...
28-
cargo build --manifest-path examples/rtfm-demo/Cargo.toml --no-default-features --features="52840"
21+
echo Building examples/rtic-demo...
22+
cargo build --manifest-path examples/rtic-demo/Cargo.toml
23+
echo Building examples/rtic-demo...
24+
cargo build --manifest-path examples/rtic-demo/Cargo.toml --no-default-features --features="51" --target thumbv6m-none-eabi
25+
echo Building examples/rtic-demo...
26+
cargo build --manifest-path examples/rtic-demo/Cargo.toml --no-default-features --features="52810" --target thumbv7em-none-eabi
27+
echo Building examples/rtic-demo...
28+
cargo build --manifest-path examples/rtic-demo/Cargo.toml --no-default-features --features="52840"
2929
echo Building examples/spi-demo...
3030
cargo build --manifest-path examples/spi-demo/Cargo.toml
3131
echo Building examples/twi-ssd1306...

0 commit comments

Comments
 (0)