aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorjrmoulton <[email protected]>2024-08-13 10:39:34 -0600
committerjrmoulton <[email protected]>2024-08-13 10:41:53 -0600
commit50619638ee5c71110430420a04d1b3113eb91945 (patch)
tree6342169b23ad695c97050b8508091857690f43eb
parentb4eb4a3d189efe5fe3716bb5dcd6396efcfab5c3 (diff)
fix examples
-rw-r--r--embassy-stm32/src/i2c/mod.rs3
-rw-r--r--examples/stm32h7/src/bin/i2c_shared.rs2
-rw-r--r--examples/stm32l4/src/bin/spe_adin1110_http_server.rs2
3 files changed, 4 insertions, 3 deletions
diff --git a/embassy-stm32/src/i2c/mod.rs b/embassy-stm32/src/i2c/mod.rs
index 6f952b8f8..c1911cd06 100644
--- a/embassy-stm32/src/i2c/mod.rs
+++ b/embassy-stm32/src/i2c/mod.rs
@@ -16,7 +16,8 @@ use embassy_hal_internal::{Peripheral, PeripheralRef};
16use embassy_sync::waitqueue::AtomicWaker; 16use embassy_sync::waitqueue::AtomicWaker;
17#[cfg(feature = "time")] 17#[cfg(feature = "time")]
18use embassy_time::{Duration, Instant}; 18use embassy_time::{Duration, Instant};
19use mode::{Master, MasterMode}; 19use mode::{MasterMode};
20pub use mode::{Master, MultiMaster};
20 21
21use crate::dma::ChannelAndRequest; 22use crate::dma::ChannelAndRequest;
22use crate::gpio::{AnyPin, SealedPin as _}; 23use crate::gpio::{AnyPin, SealedPin as _};
diff --git a/examples/stm32h7/src/bin/i2c_shared.rs b/examples/stm32h7/src/bin/i2c_shared.rs
index 6f4815582..321b35a3e 100644
--- a/examples/stm32h7/src/bin/i2c_shared.rs
+++ b/examples/stm32h7/src/bin/i2c_shared.rs
@@ -23,7 +23,7 @@ const SHTC3_WAKEUP: [u8; 2] = [0x35, 0x17];
23const SHTC3_MEASURE_RH_FIRST: [u8; 2] = [0x5c, 0x24]; 23const SHTC3_MEASURE_RH_FIRST: [u8; 2] = [0x5c, 0x24];
24const SHTC3_SLEEP: [u8; 2] = [0xb0, 0x98]; 24const SHTC3_SLEEP: [u8; 2] = [0xb0, 0x98];
25 25
26static I2C_BUS: StaticCell<NoopMutex<RefCell<I2c<'static, Async>>>> = StaticCell::new(); 26static I2C_BUS: StaticCell<NoopMutex<RefCell<I2c<'static, Async, i2c::Master>>>> = StaticCell::new();
27 27
28bind_interrupts!(struct Irqs { 28bind_interrupts!(struct Irqs {
29 I2C1_EV => i2c::EventInterruptHandler<peripherals::I2C1>; 29 I2C1_EV => i2c::EventInterruptHandler<peripherals::I2C1>;
diff --git a/examples/stm32l4/src/bin/spe_adin1110_http_server.rs b/examples/stm32l4/src/bin/spe_adin1110_http_server.rs
index bd633cecb..8f23e4083 100644
--- a/examples/stm32l4/src/bin/spe_adin1110_http_server.rs
+++ b/examples/stm32l4/src/bin/spe_adin1110_http_server.rs
@@ -60,7 +60,7 @@ pub type SpeSpiCs = ExclusiveDevice<SpeSpi, Output<'static>, Delay>;
60pub type SpeInt = exti::ExtiInput<'static>; 60pub type SpeInt = exti::ExtiInput<'static>;
61pub type SpeRst = Output<'static>; 61pub type SpeRst = Output<'static>;
62pub type Adin1110T = ADIN1110<SpeSpiCs>; 62pub type Adin1110T = ADIN1110<SpeSpiCs>;
63pub type TempSensI2c = I2c<'static, Async>; 63pub type TempSensI2c = I2c<'static, Async, i2c::Master>;
64 64
65static TEMP: AtomicI32 = AtomicI32::new(0); 65static TEMP: AtomicI32 = AtomicI32::new(0);
66 66