diff options
| author | Quentin Smith <[email protected]> | 2022-08-19 00:53:06 -0400 |
|---|---|---|
| committer | Quentin Smith <[email protected]> | 2022-08-19 00:53:41 -0400 |
| commit | 71e468681b1c074e06276d34ff00e36169c632f5 (patch) | |
| tree | ce86220caabbdc044720df8efb23de7bc4c36ea0 /examples/nrf-rtos-trace | |
| parent | 2edf532f8d8ce048137990bf74b07759428ed7c1 (diff) | |
| parent | aefa5275a2ab2cac6caef599e7adb76ce1beeddd (diff) | |
Merge branch 'master' of https://github.com/embassy-rs/embassy into rtos-trace
Diffstat (limited to 'examples/nrf-rtos-trace')
| -rw-r--r-- | examples/nrf-rtos-trace/Cargo.toml | 22 | ||||
| -rw-r--r-- | examples/nrf-rtos-trace/src/bin/rtos_trace.rs | 8 |
2 files changed, 9 insertions, 21 deletions
diff --git a/examples/nrf-rtos-trace/Cargo.toml b/examples/nrf-rtos-trace/Cargo.toml index 9c749a388..dad74235f 100644 --- a/examples/nrf-rtos-trace/Cargo.toml +++ b/examples/nrf-rtos-trace/Cargo.toml | |||
| @@ -5,38 +5,26 @@ version = "0.1.0" | |||
| 5 | 5 | ||
| 6 | [features] | 6 | [features] |
| 7 | default = ["log", "nightly"] | 7 | default = ["log", "nightly"] |
| 8 | nightly = ["embassy-executor/nightly", "embassy-nrf/nightly", "embassy-nrf/unstable-traits", "embassy-usb", "embassy-usb-serial", "embassy-usb-hid", "embassy-usb-ncm", "embedded-io/async", "embassy-net"] | 8 | nightly = ["embassy-executor/nightly", "embassy-nrf/nightly", "embassy-nrf/unstable-traits"] |
| 9 | log = [ | 9 | log = [ |
| 10 | "dep:log", | 10 | "dep:log", |
| 11 | "embassy-util/log", | 11 | "embassy-util/log", |
| 12 | "embassy-executor/log", | 12 | "embassy-executor/log", |
| 13 | "embassy-time/log", | ||
| 13 | "embassy-nrf/log", | 14 | "embassy-nrf/log", |
| 14 | "embassy-net/log", | ||
| 15 | "embassy-usb-ncm/log", | ||
| 16 | # Currently broken: | ||
| 17 | # "embassy-usb/log", | ||
| 18 | # "embassy-usb-serial/log", | ||
| 19 | # "embassy-usb-hid/log", | ||
| 20 | ] | 15 | ] |
| 21 | 16 | ||
| 22 | [dependencies] | 17 | [dependencies] |
| 23 | embassy-util = { version = "0.1.0", path = "../../embassy-util" } | 18 | embassy-util = { version = "0.1.0", path = "../../embassy-util" } |
| 24 | embassy-executor = { version = "0.1.0", path = "../../embassy-executor", features=["rtos-trace", "rtos-trace-interrupt"] } | 19 | embassy-executor = { version = "0.1.0", path = "../../embassy-executor", features=["rtos-trace", "rtos-trace-interrupt", "integrated-timers"] } |
| 20 | embassy-time = { version = "0.1.0", path = "../../embassy-time" } | ||
| 25 | embassy-nrf = { version = "0.1.0", path = "../../embassy-nrf", features = ["nrf52840", "time-driver-rtc1", "gpiote", "unstable-pac"] } | 21 | embassy-nrf = { version = "0.1.0", path = "../../embassy-nrf", features = ["nrf52840", "time-driver-rtc1", "gpiote", "unstable-pac"] } |
| 26 | embassy-net = { version = "0.1.0", path = "../../embassy-net", features = ["tcp", "dhcpv4", "medium-ethernet", "pool-16"], optional = true } | ||
| 27 | embassy-usb = { version = "0.1.0", path = "../../embassy-usb", optional = true } | ||
| 28 | embassy-usb-serial = { version = "0.1.0", path = "../../embassy-usb-serial", optional = true } | ||
| 29 | embassy-usb-hid = { version = "0.1.0", path = "../../embassy-usb-hid", optional = true } | ||
| 30 | embassy-usb-ncm = { version = "0.1.0", path = "../../embassy-usb-ncm", optional = true } | ||
| 31 | embedded-io = "0.3.0" | ||
| 32 | 22 | ||
| 33 | cortex-m = "0.7.3" | 23 | cortex-m = { version = "0.7.6", features = ["critical-section-single-core"] } |
| 34 | cortex-m-rt = "0.7.0" | 24 | cortex-m-rt = "0.7.0" |
| 35 | panic-probe = { version = "0.3" } | 25 | panic-probe = { version = "0.3" } |
| 36 | futures = { version = "0.3.17", default-features = false, features = ["async-await"] } | 26 | futures = { version = "0.3.17", default-features = false, features = ["async-await"] } |
| 37 | rand = { version = "0.8.4", default-features = false } | 27 | rand = { version = "0.8.4", default-features = false } |
| 38 | embedded-storage = "0.3.0" | ||
| 39 | usbd-hid = "0.5.2" | ||
| 40 | serde = { version = "1.0.136", default-features = false } | 28 | serde = { version = "1.0.136", default-features = false } |
| 41 | rtos-trace = "0.1.3" | 29 | rtos-trace = "0.1.3" |
| 42 | systemview-target = { version = "0.1.1", features = ["callbacks-app", "callbacks-os", "log", "cortex-m"] } | 30 | systemview-target = { version = "0.1.1", features = ["callbacks-app", "callbacks-os", "log", "cortex-m"] } |
diff --git a/examples/nrf-rtos-trace/src/bin/rtos_trace.rs b/examples/nrf-rtos-trace/src/bin/rtos_trace.rs index 5699fe8e2..7d1ad87c8 100644 --- a/examples/nrf-rtos-trace/src/bin/rtos_trace.rs +++ b/examples/nrf-rtos-trace/src/bin/rtos_trace.rs | |||
| @@ -4,9 +4,8 @@ | |||
| 4 | 4 | ||
| 5 | use core::task::Poll; | 5 | use core::task::Poll; |
| 6 | 6 | ||
| 7 | use embassy_executor::executor::Spawner; | 7 | use embassy_executor::Spawner; |
| 8 | use embassy_executor::time::{Duration, Instant, Timer}; | 8 | use embassy_time::{Duration, Instant, Timer}; |
| 9 | use embassy_nrf::Peripherals; | ||
| 10 | #[cfg(feature = "log")] | 9 | #[cfg(feature = "log")] |
| 11 | use log::*; | 10 | use log::*; |
| 12 | use panic_probe as _; | 11 | use panic_probe as _; |
| @@ -55,7 +54,8 @@ async fn run3() { | |||
| 55 | } | 54 | } |
| 56 | 55 | ||
| 57 | #[embassy_executor::main] | 56 | #[embassy_executor::main] |
| 58 | async fn main(spawner: Spawner, _p: Peripherals) { | 57 | async fn main(spawner: Spawner) { |
| 58 | let _p = embassy_nrf::init(Default::default()); | ||
| 59 | LOGGER.init(); | 59 | LOGGER.init(); |
| 60 | #[cfg(feature = "log")] | 60 | #[cfg(feature = "log")] |
| 61 | { | 61 | { |
