pub enum I2CAddress {
Primary,
Secondary,
Other(u8),
}Expand description
I2C Slave Address
To determine the slave address of your device you can use i2cdetect -y 1 on linux.
The 7-bit device address is 111011x. The 6 MSB bits are fixed.
The last bit is changeable by SDO value and can be changed during operation.
Connecting SDO to GND results in slave address 1110110 (0x76); connecting it to V DDIO results in slave
address 1110111 (0x77), which is the same as BMP280’s I2C address.
Variants§
Primary
Primary Slave Address 0x76
Secondary
Secondary Slave Address 0x77
Other(u8)
Alternative address
Implementations§
Trait Implementations§
Source§impl Clone for I2CAddress
impl Clone for I2CAddress
Source§fn clone(&self) -> I2CAddress
fn clone(&self) -> I2CAddress
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for I2CAddress
impl Debug for I2CAddress
Source§impl Default for I2CAddress
impl Default for I2CAddress
Source§fn default() -> I2CAddress
fn default() -> I2CAddress
Returns the “default value” for a type. Read more
impl Copy for I2CAddress
Auto Trait Implementations§
impl Freeze for I2CAddress
impl RefUnwindSafe for I2CAddress
impl Send for I2CAddress
impl Sync for I2CAddress
impl Unpin for I2CAddress
impl UnwindSafe for I2CAddress
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