diff options
| author | Timo Kröger <[email protected]> | 2021-07-23 14:24:38 +0200 |
|---|---|---|
| committer | Timo Kröger <[email protected]> | 2021-07-23 17:54:13 +0200 |
| commit | 5ac91933ff0e4643823c77b357d90e82007fc9fb (patch) | |
| tree | 5f252cde081a002f09659059bf746bf2896a3d16 /examples/stm32wb55 | |
| parent | ec5d44333ab6c0711424699efb2e782baf0124c7 (diff) | |
stm32: No need to enable GPIO clocks manually
Diffstat (limited to 'examples/stm32wb55')
| -rw-r--r-- | examples/stm32wb55/Cargo.toml | 1 | ||||
| -rw-r--r-- | examples/stm32wb55/src/bin/blinky.rs | 8 |
2 files changed, 0 insertions, 9 deletions
diff --git a/examples/stm32wb55/Cargo.toml b/examples/stm32wb55/Cargo.toml index d3d128e87..92813ccd0 100644 --- a/examples/stm32wb55/Cargo.toml +++ b/examples/stm32wb55/Cargo.toml | |||
| @@ -21,7 +21,6 @@ embassy = { version = "0.1.0", path = "../../embassy", features = ["defmt", "def | |||
| 21 | embassy-traits = { version = "0.1.0", path = "../../embassy-traits", features = ["defmt"] } | 21 | embassy-traits = { version = "0.1.0", path = "../../embassy-traits", features = ["defmt"] } |
| 22 | embassy-stm32 = { version = "0.1.0", path = "../../embassy-stm32", features = ["defmt", "defmt-trace", "stm32wb55cc"] } | 22 | embassy-stm32 = { version = "0.1.0", path = "../../embassy-stm32", features = ["defmt", "defmt-trace", "stm32wb55cc"] } |
| 23 | embassy-extras = {version = "0.1.0", path = "../../embassy-extras" } | 23 | embassy-extras = {version = "0.1.0", path = "../../embassy-extras" } |
| 24 | stm32wb-pac = "0.2" | ||
| 25 | 24 | ||
| 26 | defmt = "0.2.0" | 25 | defmt = "0.2.0" |
| 27 | defmt-rtt = "0.2.0" | 26 | defmt-rtt = "0.2.0" |
diff --git a/examples/stm32wb55/src/bin/blinky.rs b/examples/stm32wb55/src/bin/blinky.rs index d53ad611a..ae11c9861 100644 --- a/examples/stm32wb55/src/bin/blinky.rs +++ b/examples/stm32wb55/src/bin/blinky.rs | |||
| @@ -13,19 +13,11 @@ use embedded_hal::digital::v2::OutputPin; | |||
| 13 | use example_common::*; | 13 | use example_common::*; |
| 14 | 14 | ||
| 15 | use cortex_m_rt::entry; | 15 | use cortex_m_rt::entry; |
| 16 | use stm32wb_pac as pac; | ||
| 17 | 16 | ||
| 18 | #[entry] | 17 | #[entry] |
| 19 | fn main() -> ! { | 18 | fn main() -> ! { |
| 20 | info!("Hello World!"); | 19 | info!("Hello World!"); |
| 21 | 20 | ||
| 22 | let pp = pac::Peripherals::take().unwrap(); | ||
| 23 | |||
| 24 | pp.RCC.ahb2enr.modify(|_, w| { | ||
| 25 | w.gpioben().set_bit(); | ||
| 26 | w | ||
| 27 | }); | ||
| 28 | |||
| 29 | let p = embassy_stm32::init(Default::default()); | 21 | let p = embassy_stm32::init(Default::default()); |
| 30 | 22 | ||
| 31 | let mut led = Output::new(p.PB0, Level::High, Speed::Low); | 23 | let mut led = Output::new(p.PB0, Level::High, Speed::Low); |
