#[repr(u8)]pub enum I2cMode {
Master = 0,
Slave = 1,
}
Expand description
Set master or slave mode. Sets the __ register, _ field.
Variants§
Master = 0
In Master mode, the I2C interface initiates a data transfer and generates the clock signal. A serial data transfer always begins with a START condition and ends with a STOP condition. Both START and STOP conditions are generated in master mode by software.
Slave = 1
In Slave mode, the interface is capable of recognizing its own addresses (7 or 10-bit), and the general call address. The general call address detection can be enabled or disabled by software. The reserved SMBus addresses can also be enabled by software.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for I2cMode
impl RefUnwindSafe for I2cMode
impl Send for I2cMode
impl Sync for I2cMode
impl Unpin for I2cMode
impl UnwindSafe for I2cMode
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