Struct i2cdev::linux::LinuxI2CMessage
source · #[repr(C)]pub struct LinuxI2CMessage<'a> { /* private fields */ }
Expand description
Linux I2C message
Implementations§
source§impl<'a> LinuxI2CMessage<'a>
impl<'a> LinuxI2CMessage<'a>
sourcepub fn with_address(self, slave_address: u16) -> Self
pub fn with_address(self, slave_address: u16) -> Self
Set the target device address for the message
sourcepub fn with_flags(self, flags: I2CMessageFlags) -> Self
pub fn with_flags(self, flags: I2CMessageFlags) -> Self
Set optional message flags
Trait Implementations§
source§impl<'a> I2CMessage<'a> for LinuxI2CMessage<'a>
impl<'a> I2CMessage<'a> for LinuxI2CMessage<'a>
source§fn read(data: &'a mut [u8]) -> LinuxI2CMessage<'a>
fn read(data: &'a mut [u8]) -> LinuxI2CMessage<'a>
Read data from device
source§fn write(data: &'a [u8]) -> LinuxI2CMessage<'a>
fn write(data: &'a [u8]) -> LinuxI2CMessage<'a>
Write data to device
Auto Trait Implementations§
impl<'a> RefUnwindSafe for i2c_msg<'a>
impl<'a> !Send for i2c_msg<'a>
impl<'a> !Sync for i2c_msg<'a>
impl<'a> Unpin for i2c_msg<'a>
impl<'a> !UnwindSafe for i2c_msg<'a>
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