pub struct I3c<'d, M: Mode> { /* private fields */ }Expand description
I3C controller driver.
Implementations§
Source§impl<'d, M: Mode> I3c<'d, M>
impl<'d, M: Mode> I3c<'d, M>
Sourcepub fn blocking_read(
&mut self,
address: u8,
read: &mut [u8],
bus_type: BusType,
) -> Result<(), IOError>
pub fn blocking_read( &mut self, address: u8, read: &mut [u8], bus_type: BusType, ) -> Result<(), IOError>
Read from address into buffer blocking caller until done.
Source§impl<'d> I3c<'d, Async>
impl<'d> I3c<'d, Async>
Sourcepub fn new_async<T: Instance>(
peri: Peri<'d, T>,
scl: Peri<'d, impl SclPin<T>>,
sda: Peri<'d, impl SdaPin<T>>,
_irq: impl Binding<T::Interrupt, InterruptHandler<T>> + 'd,
config: Config,
) -> Result<Self, SetupError>
pub fn new_async<T: Instance>( peri: Peri<'d, T>, scl: Peri<'d, impl SclPin<T>>, sda: Peri<'d, impl SdaPin<T>>, _irq: impl Binding<T::Interrupt, InterruptHandler<T>> + 'd, config: Config, ) -> Result<Self, SetupError>
Create a new asynchronous instance of the I3C controller bus driver.
Any external pin will be placed into Disabled state upon Drop.
Sourcepub fn async_read<'a>(
&mut self,
address: u8,
read: &'a mut [u8],
bus_type: BusType,
) -> impl Future<Output = Result<(), IOError>> + use<'_, 'a, 'd>
pub fn async_read<'a>( &mut self, address: u8, read: &'a mut [u8], bus_type: BusType, ) -> impl Future<Output = Result<(), IOError>> + use<'_, 'a, 'd>
Read from address into buffer asynchronously.
Trait Implementations§
Source§impl<'d> I2c for I3c<'d, Async>
impl<'d> I2c for I3c<'d, Async>
Source§async fn transaction(
&mut self,
address: u8,
operations: &mut [Operation<'_>],
) -> Result<(), Self::Error>
async fn transaction( &mut self, address: u8, operations: &mut [Operation<'_>], ) -> Result<(), Self::Error>
Execute the provided operations on the I2C bus as a single transaction. Read more
Source§impl<'d, M: Mode> I2c for I3c<'d, M>
impl<'d, M: Mode> I2c for I3c<'d, M>
Source§fn transaction(
&mut self,
address: u8,
operations: &mut [Operation<'_>],
) -> Result<(), Self::Error>
fn transaction( &mut self, address: u8, operations: &mut [Operation<'_>], ) -> Result<(), Self::Error>
Execute the provided operations on the I2C bus. Read more
Source§impl<'d, M: Mode> SetConfig for I3c<'d, M>
impl<'d, M: Mode> SetConfig for I3c<'d, M>
Source§type ConfigError = SetupError
type ConfigError = SetupError
The error type that can occur if
set_config fails.Source§fn set_config(&mut self, config: &Self::Config) -> Result<(), Self::ConfigError>
fn set_config(&mut self, config: &Self::Config) -> Result<(), Self::ConfigError>
Set the configuration of the driver.
Source§impl<'d, M: Mode> Transactional for I3c<'d, M>
impl<'d, M: Mode> Transactional for I3c<'d, M>
Auto Trait Implementations§
impl<'d, M> Freeze for I3c<'d, M>
impl<'d, M> !RefUnwindSafe for I3c<'d, M>
impl<'d, M> Send for I3c<'d, M>where
M: Send,
impl<'d, M> Sync for I3c<'d, M>where
M: Sync,
impl<'d, M> Unpin for I3c<'d, M>where
M: Unpin,
impl<'d, M> !UnwindSafe for I3c<'d, M>
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more