diff options
| author | WillaWillNot <[email protected]> | 2025-11-22 16:48:19 -0500 |
|---|---|---|
| committer | WillaWillNot <[email protected]> | 2025-11-22 16:48:46 -0500 |
| commit | 764c921a573e42f510a74d61f31302b8609bbd6c (patch) | |
| tree | 546d74daf73f501f7a29a929793ba2a55b47f3a4 /examples/stm32f4 | |
| parent | 54d57bc72f0e2b3eef0fa92d0b730ed6efd7bcaa (diff) | |
Reverted adding AnyBinding, removed AnyChannel, removed ability for ExtiInput to accept AnyPin and AnyChannel arguments, added ExtiPin trait for all pins which is lost on converstion to AnyPin and contains type-level ExtiChannel information
Diffstat (limited to 'examples/stm32f4')
| -rw-r--r-- | examples/stm32f4/src/bin/button_exti.rs | 7 | ||||
| -rw-r--r-- | examples/stm32f4/src/bin/eth_w5500.rs | 7 | ||||
| -rw-r--r-- | examples/stm32f4/src/bin/usb_hid_keyboard.rs | 7 |
3 files changed, 3 insertions, 18 deletions
diff --git a/examples/stm32f4/src/bin/button_exti.rs b/examples/stm32f4/src/bin/button_exti.rs index 93560ed06..e7e1549a8 100644 --- a/examples/stm32f4/src/bin/button_exti.rs +++ b/examples/stm32f4/src/bin/button_exti.rs | |||
| @@ -18,12 +18,7 @@ async fn main(_spawner: Spawner) { | |||
| 18 | let p = embassy_stm32::init(Default::default()); | 18 | let p = embassy_stm32::init(Default::default()); |
| 19 | info!("Hello World!"); | 19 | info!("Hello World!"); |
| 20 | 20 | ||
| 21 | let mut button = ExtiInput::new( | 21 | let mut button = ExtiInput::new(p.PC13, p.EXTI13, Pull::Down, Irqs); |
| 22 | p.PC13, | ||
| 23 | p.EXTI13, | ||
| 24 | Pull::Down, | ||
| 25 | Irqs::as_any::<interrupt::typelevel::EXTI15_10, exti::InterruptHandler<interrupt::typelevel::EXTI15_10>>(), | ||
| 26 | ); | ||
| 27 | 22 | ||
| 28 | info!("Press the USER button..."); | 23 | info!("Press the USER button..."); |
| 29 | 24 | ||
diff --git a/examples/stm32f4/src/bin/eth_w5500.rs b/examples/stm32f4/src/bin/eth_w5500.rs index f59f1d3b5..e274d2a66 100644 --- a/examples/stm32f4/src/bin/eth_w5500.rs +++ b/examples/stm32f4/src/bin/eth_w5500.rs | |||
| @@ -76,12 +76,7 @@ async fn main(spawner: Spawner) -> ! { | |||
| 76 | let cs = Output::new(p.PA4, Level::High, Speed::VeryHigh); | 76 | let cs = Output::new(p.PA4, Level::High, Speed::VeryHigh); |
| 77 | let spi = unwrap!(ExclusiveDevice::new(spi, cs, Delay)); | 77 | let spi = unwrap!(ExclusiveDevice::new(spi, cs, Delay)); |
| 78 | 78 | ||
| 79 | let w5500_int = ExtiInput::new( | 79 | let w5500_int = ExtiInput::new(p.PB0, p.EXTI0, Pull::Up, Irqs); |
| 80 | p.PB0, | ||
| 81 | p.EXTI0, | ||
| 82 | Pull::Up, | ||
| 83 | Irqs::as_any::<interrupt::typelevel::EXTI0, exti::InterruptHandler<interrupt::typelevel::EXTI0>>(), | ||
| 84 | ); | ||
| 85 | let w5500_reset = Output::new(p.PB1, Level::High, Speed::VeryHigh); | 80 | let w5500_reset = Output::new(p.PB1, Level::High, Speed::VeryHigh); |
| 86 | 81 | ||
| 87 | let mac_addr = [0x02, 234, 3, 4, 82, 231]; | 82 | let mac_addr = [0x02, 234, 3, 4, 82, 231]; |
diff --git a/examples/stm32f4/src/bin/usb_hid_keyboard.rs b/examples/stm32f4/src/bin/usb_hid_keyboard.rs index b5a7e86e4..2d834dcf7 100644 --- a/examples/stm32f4/src/bin/usb_hid_keyboard.rs +++ b/examples/stm32f4/src/bin/usb_hid_keyboard.rs | |||
| @@ -124,12 +124,7 @@ async fn main(_spawner: Spawner) { | |||
| 124 | 124 | ||
| 125 | let (reader, mut writer) = hid.split(); | 125 | let (reader, mut writer) = hid.split(); |
| 126 | 126 | ||
| 127 | let mut button = ExtiInput::new( | 127 | let mut button = ExtiInput::new(p.PC13, p.EXTI13, Pull::Down, Irqs); |
| 128 | p.PC13, | ||
| 129 | p.EXTI13, | ||
| 130 | Pull::Down, | ||
| 131 | Irqs::as_any::<interrupt::typelevel::EXTI15_10, exti::InterruptHandler<interrupt::typelevel::EXTI15_10>>(), | ||
| 132 | ); | ||
| 133 | 128 | ||
| 134 | // Do stuff with the class! | 129 | // Do stuff with the class! |
| 135 | let in_fut = async { | 130 | let in_fut = async { |
