i2c

I2C

I2C is a half-duplex synchronous data bus intended for lower-speed transfers. It uses two lines: SCL (clock) and SDA (data). Each peripheral device must have a unique 7-bit address. During a transmission, the address is shifted left and the least significant bit used to indicate transfer direction. In practice, device addresses are often given in 8-bit form (less the direction bit) on datasheets.

Both SDA and SCL require pull-up resistors. When using devices on breakout boards, always check whether the boards contain those resistors.

On Arduino devices, I2C is implemented in the Wire library. This library expects 7-bit addresses.

  • i2c.txt
  • Last modified: 2023-05-08 01:34
  • by asdf