Skip to main content

How I2C Communication works?

I2C or Inter-IC (integrated circuit) bus

How I2C Communication works?

As you can see in Figure 2, the master begins the communication by issuing the start condition (S). The master continues by sending a unique 7-bit slave device address, with the most significant bit (MSB) first. The eighth bit after the start, read/not-write (), specifies whether the slave is now to receive (0) or to transmit (1). This is followed by an ACK bit issued by the receiver, acknowledging receipt of the previous byte. Then the transmitter (slave or master, as indicated by the bit) transmits a byte of data starting with the MSB. At the end of the byte, the receiver (whether master or slave) issues a new ACK bit. This 9-bit pattern is repeated if more bytes need to be transmitted.
In a write transaction (slave receiving), when the master is done transmitting all of the data bytes it wants to send, it monitors the last ACK and then issues the stop condition (P). In a read transaction (slave transmitting), the master does not acknowledge the final byte it receives. This tells the slave that its transmission is done. The master then issues the stop condition.

Advantages of I2C

  • Only two bus lines are required to establish full-fledged bus.
  • Each slave device connected is uniquely addressable using slave addresses
  • Can choose a short 7 bit addressing or 10 bit addressing (which can accommodate large number of devices on the same bus, but less popular).
  • No strict baud rate specified since the clock is driven directly by the master. Supports up to 3.4 Mbits/sec transfer speeds
  • True multimaster support with up to 8 masters in a single bus system.
  • Very simple protocol which can be emulated by microcontrollers without integrated I2C peripheral device. And its Inexpensive
Limitations of I2C
  • 7 bit addressing supports only a very small number of devices.
  • Different devices from different manufacturers come with hard coded slave address or address will be configurable in a small range only. This can lead to address clashes sometimes.
  • No automatic bus configuration or plug and play
Applications of I2C
  • I²C is appropriate for peripherals where simplicity and low manufacturing cost are more important than speed. Common applications of the I²C bus are:
  • Reading configuration data from SPD EEPROMs on SDRAM, DDR SDRAM, DDR2 SDRAM memory sticks (DIMM) and other stacked PC boards
  • Supporting systems management for PCI cards, through an SMBus 2.0 connection.
  • Accessing NVRAM chips that keep user settings.
  • Accessing low speed DACs and ADCs.
  • Changing contrast, hue, and color balance settings in monitors (Display Data Channel).
  • Changing sound volume in intelligent speakers.
  • Controlling OLED/LCD displays, like in a cellphone.
  • Reading hardware monitors and diagnostic sensors, like a CPU thermostat and fan speed.
  • Reading real time clocks.
  • Turning on and turning off the power supply of system components.
  • A particular strength of I²C is that a microcontroller can control a network of device chips with just two general-purpose I/O pins and software.
  • Peripherals can also be added to or removed from the I²C bus while the system is running, which makes it ideal for applications that require hot swapping of components.


Characteristics Of The I2C-Bus

Comments

Popular posts from this blog

CAN INTERVIEW QUESTIONS

Qualifiers and Modifier in C

RTOS Real time operating system interview questions

CAN INTERVIEW QUESTIONS 2

What is UDS protocol

Memory mapping in c

TOP IOT PLATFORMS