aboutsummaryrefslogtreecommitdiff
path: root/docs
diff options
context:
space:
mode:
Diffstat (limited to 'docs')
-rw-r--r--docs/modules/ROOT/examples/basic/Cargo.toml2
-rw-r--r--docs/modules/ROOT/examples/basic/src/main.rs8
-rw-r--r--docs/modules/ROOT/examples/layer-by-layer/Cargo.toml2
-rw-r--r--docs/modules/ROOT/examples/layer-by-layer/blinky-async/Cargo.toml2
-rw-r--r--docs/modules/ROOT/examples/layer-by-layer/blinky-async/src/main.rs4
5 files changed, 9 insertions, 9 deletions
diff --git a/docs/modules/ROOT/examples/basic/Cargo.toml b/docs/modules/ROOT/examples/basic/Cargo.toml
index ed1c3cb1c..59e1a437a 100644
--- a/docs/modules/ROOT/examples/basic/Cargo.toml
+++ b/docs/modules/ROOT/examples/basic/Cargo.toml
@@ -5,7 +5,7 @@ name = "embassy-basic-example"
5version = "0.1.0" 5version = "0.1.0"
6 6
7[dependencies] 7[dependencies]
8embassy = { version = "0.1.0", path = "../../../../../embassy", features = ["defmt", "nightly"] } 8embassy-executor = { version = "0.1.0", path = "../../../../../embassy-executor", features = ["defmt", "nightly"] }
9embassy-nrf = { version = "0.1.0", path = "../../../../../embassy-nrf", features = ["defmt", "nrf52840", "time-driver-rtc1", "gpiote", "nightly"] } 9embassy-nrf = { version = "0.1.0", path = "../../../../../embassy-nrf", features = ["defmt", "nrf52840", "time-driver-rtc1", "gpiote", "nightly"] }
10 10
11defmt = "0.3" 11defmt = "0.3"
diff --git a/docs/modules/ROOT/examples/basic/src/main.rs b/docs/modules/ROOT/examples/basic/src/main.rs
index 461741fd7..cec39fd91 100644
--- a/docs/modules/ROOT/examples/basic/src/main.rs
+++ b/docs/modules/ROOT/examples/basic/src/main.rs
@@ -3,14 +3,14 @@
3#![feature(type_alias_impl_trait)] 3#![feature(type_alias_impl_trait)]
4 4
5use defmt::*; 5use defmt::*;
6use embassy::executor::Spawner; 6use embassy_executor::executor::Spawner;
7use embassy::time::{Duration, Timer}; 7use embassy_executor::time::{Duration, Timer};
8use embassy_nrf::gpio::{Level, Output, OutputDrive}; 8use embassy_nrf::gpio::{Level, Output, OutputDrive};
9use embassy_nrf::peripherals::P0_13; 9use embassy_nrf::peripherals::P0_13;
10use embassy_nrf::Peripherals; 10use embassy_nrf::Peripherals;
11use {defmt_rtt as _, panic_probe as _}; // global logger 11use {defmt_rtt as _, panic_probe as _}; // global logger
12 12
13#[embassy::task] 13#[embassy_executor::task]
14async fn blinker(mut led: Output<'static, P0_13>, interval: Duration) { 14async fn blinker(mut led: Output<'static, P0_13>, interval: Duration) {
15 loop { 15 loop {
16 led.set_high(); 16 led.set_high();
@@ -20,7 +20,7 @@ async fn blinker(mut led: Output<'static, P0_13>, interval: Duration) {
20 } 20 }
21} 21}
22 22
23#[embassy::main] 23#[embassy_executor::main]
24async fn main(spawner: Spawner, p: Peripherals) { 24async fn main(spawner: Spawner, p: Peripherals) {
25 let led = Output::new(p.P0_13, Level::Low, OutputDrive::Standard); 25 let led = Output::new(p.P0_13, Level::Low, OutputDrive::Standard);
26 unwrap!(spawner.spawn(blinker(led, Duration::from_millis(300)))); 26 unwrap!(spawner.spawn(blinker(led, Duration::from_millis(300))));
diff --git a/docs/modules/ROOT/examples/layer-by-layer/Cargo.toml b/docs/modules/ROOT/examples/layer-by-layer/Cargo.toml
index 2dca3cc8d..9048d9302 100644
--- a/docs/modules/ROOT/examples/layer-by-layer/Cargo.toml
+++ b/docs/modules/ROOT/examples/layer-by-layer/Cargo.toml
@@ -8,7 +8,7 @@ members = [
8] 8]
9 9
10[patch.crates-io] 10[patch.crates-io]
11embassy = { path = "../../../../../embassy" } 11embassy-executor = { path = "../../../../../embassy-executor" }
12embassy-stm32 = { path = "../../../../../embassy-stm32" } 12embassy-stm32 = { path = "../../../../../embassy-stm32" }
13stm32-metapac = { path = "../../../../../stm32-metapac" } 13stm32-metapac = { path = "../../../../../stm32-metapac" }
14 14
diff --git a/docs/modules/ROOT/examples/layer-by-layer/blinky-async/Cargo.toml b/docs/modules/ROOT/examples/layer-by-layer/blinky-async/Cargo.toml
index e0c63251e..e2933076f 100644
--- a/docs/modules/ROOT/examples/layer-by-layer/blinky-async/Cargo.toml
+++ b/docs/modules/ROOT/examples/layer-by-layer/blinky-async/Cargo.toml
@@ -7,7 +7,7 @@ edition = "2021"
7cortex-m = "0.7" 7cortex-m = "0.7"
8cortex-m-rt = "0.7" 8cortex-m-rt = "0.7"
9embassy-stm32 = { version = "0.1.0", features = ["stm32l475vg", "memory-x", "exti"], default-features = false } 9embassy-stm32 = { version = "0.1.0", features = ["stm32l475vg", "memory-x", "exti"], default-features = false }
10embassy = { version = "0.1.0", default-features = false, features = ["nightly"] } 10embassy-executor = { version = "0.1.0", default-features = false, features = ["nightly"] }
11 11
12defmt = "0.3.0" 12defmt = "0.3.0"
13defmt-rtt = "0.3.0" 13defmt-rtt = "0.3.0"
diff --git a/docs/modules/ROOT/examples/layer-by-layer/blinky-async/src/main.rs b/docs/modules/ROOT/examples/layer-by-layer/blinky-async/src/main.rs
index 56bc698da..b944a7994 100644
--- a/docs/modules/ROOT/examples/layer-by-layer/blinky-async/src/main.rs
+++ b/docs/modules/ROOT/examples/layer-by-layer/blinky-async/src/main.rs
@@ -2,13 +2,13 @@
2#![no_main] 2#![no_main]
3#![feature(type_alias_impl_trait)] 3#![feature(type_alias_impl_trait)]
4 4
5use embassy::executor::Spawner; 5use embassy_executor::executor::Spawner;
6use embassy_stm32::exti::ExtiInput; 6use embassy_stm32::exti::ExtiInput;
7use embassy_stm32::gpio::{Input, Level, Output, Pull, Speed}; 7use embassy_stm32::gpio::{Input, Level, Output, Pull, Speed};
8use embassy_stm32::Peripherals; 8use embassy_stm32::Peripherals;
9use {defmt_rtt as _, panic_probe as _}; 9use {defmt_rtt as _, panic_probe as _};
10 10
11#[embassy::main] 11#[embassy_executor::main]
12async fn main(_s: Spawner, p: Peripherals) { 12async fn main(_s: Spawner, p: Peripherals) {
13 let mut led = Output::new(p.PB14, Level::Low, Speed::VeryHigh); 13 let mut led = Output::new(p.PB14, Level::Low, Speed::VeryHigh);
14 let mut button = ExtiInput::new(Input::new(p.PC13, Pull::Up), p.EXTI13); 14 let mut button = ExtiInput::new(Input::new(p.PC13, Pull::Up), p.EXTI13);