Add embassy-embedded-hal nightly feature
This commit is contained in:
@ -27,6 +27,7 @@ use core::future::Future;
|
||||
|
||||
use embassy::blocking_mutex::raw::RawMutex;
|
||||
use embassy::mutex::Mutex;
|
||||
#[cfg(feature = "nightly")]
|
||||
use embedded_hal_async::i2c;
|
||||
|
||||
use crate::SetConfig;
|
||||
@ -64,6 +65,7 @@ where
|
||||
type Error = I2cBusDeviceError<BUS::Error>;
|
||||
}
|
||||
|
||||
#[cfg(feature = "nightly")]
|
||||
impl<M, BUS> i2c::I2c for I2cBusDevice<'_, M, BUS>
|
||||
where
|
||||
M: RawMutex + 'static,
|
||||
@ -139,6 +141,7 @@ where
|
||||
type Error = I2cBusDeviceError<BUS::Error>;
|
||||
}
|
||||
|
||||
#[cfg(feature = "nightly")]
|
||||
impl<M, BUS> i2c::I2c for I2cBusDeviceWithConfig<'_, M, BUS>
|
||||
where
|
||||
M: RawMutex + 'static,
|
||||
|
@ -32,6 +32,7 @@ use embassy::blocking_mutex::raw::RawMutex;
|
||||
use embassy::mutex::Mutex;
|
||||
use embedded_hal_1::digital::blocking::OutputPin;
|
||||
use embedded_hal_1::spi::ErrorType;
|
||||
#[cfg(feature = "nightly")]
|
||||
use embedded_hal_async::spi;
|
||||
|
||||
use crate::SetConfig;
|
||||
@ -74,6 +75,7 @@ where
|
||||
type Error = SpiBusDeviceError<BUS::Error, CS::Error>;
|
||||
}
|
||||
|
||||
#[cfg(feature = "nightly")]
|
||||
impl<M, BUS, CS> spi::SpiDevice for SpiBusDevice<'_, M, BUS, CS>
|
||||
where
|
||||
M: RawMutex + 'static,
|
||||
@ -133,6 +135,7 @@ where
|
||||
type Error = SpiBusDeviceError<BUS::Error, CS::Error>;
|
||||
}
|
||||
|
||||
#[cfg(feature = "nightly")]
|
||||
impl<M, BUS, CS> spi::SpiDevice for SpiBusDeviceWithConfig<'_, M, BUS, CS>
|
||||
where
|
||||
M: RawMutex + 'static,
|
||||
|
Reference in New Issue
Block a user