O'Reilly logo

BeagleBone Essentials by Rodolfo Giometti

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

The I2C bus in Linux

Each I2C device has a well-defined 7 bit address that the master must use in order to communicate with a device. This address is not assigned at runtime and, as for the USB devices, it's assigned by the board designer by setting chip's pins.

Tip

Typically, the chip manufacturer sets the most significant 3 or 4 bits, and the board designer can set the remaining bits in order to suit his/her needs.

Another thing to be outlined regarding the I2C bus is that for each message, the master must specify whether the message wants to read or write data from the slave. This special action is done by adding a final bit (the least significant bit) to the slave address, and the master uses 0 to write data and 1 to read data from the slave. ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required