# I2C
Source: [https://docs.qualcomm.com/doc/80-70014-8/topic/i2c.html](https://docs.qualcomm.com/doc/80-70014-8/topic/i2c.html)
Interintegrated circuit (I2C) is a bidirectional 2-wire bus for an efficient inter‑IC
control bus developed by Philips in the 1980s. Every target on the bus has its own
unique address (registered with the I2C general body headed by Philips). The I2C core
supports a multicontroller mode and 10‑bit target address and 10‑bit extendable
address.
### I2C communication sequence overview
The communication sequence between the controller and targets in I2C is as follows.
It is also illustrated in the following figure.
1. The START sequence is sent by the controller to all the target devices on
the bus.
2. The controller sends an address of the device that it wants to access, along
with the read and write operation.
3. The target devices compare this address with their own to find an identical
address.
- Both addresses are identical: target sends an ACK signal.
- Both addresses are not identical: targets wait until the bus is
released by the STOP sequence.
4. The controller starts to transmit and receive data after receiving the ACK
signal.
5. The controller sends a STOP condition, after completion.
Figure : I2C sequence

For example, 1111-0XX listed in the I2C specification cannot be used by any target
device. High-speed mode with 3.4 MHz clock frequency.
Following are the I2C modes and supported speeds.
- Standard mode: 100 kbps
- Fast mode: 400 kbps
- Fast mode plus: 1 Mbps
The maximum supported bandwidth is up to 1 MHz.
### I2C data packet format
The controller sends a 7‑bit or 10‑bit address. Along with the address, a 1‑bit
read/write indicating the type of operation is also sent. Data is transferred in
sequences of 8 bits placed on an SDA line. For every byte transferred, the device
receiving the data sends back an ACK bit (totaling nine clock pulses).
- ACK bit LOW: it receives the data and is ready to accept the next byte.
- ACK bit HIGH: it receives the data and cannot accept further data. The
controller then terminates the transmission with the STOP sequence.
Figure : I2C data packet
### I2C sequences
When the SCL is high, the SDA must remain stable and
cannot change. Only when the clock line is low can the data line change.
However, there are two exceptions: START and STOP sequences.

## I2C features
Source: [https://docs.qualcomm.com/doc/80-70014-8/topic/i2c.html](https://docs.qualcomm.com/doc/80-70014-8/topic/i2c.html)
This section provides information about the I2C serial engine transfer modes and various
use cases supporting the different transfer modes. This section also describes the FIFO
and DMA features enabled in the various I2C subsystem drivers.
### Linux
I2C supports standard protocol-defined speeds.
### Boot
- Supports FIFO mode.
- Supports 100 kHz, 400 kHz, and 1000 kHz bus speeds.
- Supports 7‑bit target address as per the I2C specification.
### aDSP/TrustZone/SDC
- Supports 100 kHz, 400 kHz, and 1000 kHz bus speeds.
- Supports 7‑bit target address as per the I2C specification.
## I2C interface
Source: [https://docs.qualcomm.com/doc/80-70014-8/topic/i2c.html](https://docs.qualcomm.com/doc/80-70014-8/topic/i2c.html)
This section provides information about the subsystem driver, kernel device tree nodes,
and related documentation.
### Linux
| File type | Description |
| --- | --- |
| Device tree source | For device tree properties of chipset configurations of QUP v3
serial engine interface device nodes, and I2C device nodes,
see [https://git.linaro.org/kernel-org/linux-next.git/tree/arch/arm64/boot/dts/qcom/sc7280.dtsi](https://git.linaro.org/kernel-org/linux-next.git/tree/arch/arm64/boot/dts/qcom/sc7280.dtsi). |
| `Pinctrl` settings | For device tree properties of GPIO settings for QUP v3 serial
engine interface for I2C device nodes, see [https://git.linaro.org/kernel-org/linux-next.git/tree/arch/arm64/boot/dts/qcom/sc7280.dtsi](https://git.linaro.org/kernel-org/linux-next.git/tree/arch/arm64/boot/dts/qcom/sc7280.dtsi). |
| TrustZone settings | For TrustZone access control settings to load the QUP v3 serial
engine I2C firmware for different subsystems, see /firmware/qualcomm-linux-spf-1-0\_ap\_standard\_oem\_nomodem/TZ.XF.5.0/trustzone\_images/core/settings/buses/qup\_accesscontrol/qupv3/config/<chipset>/QUPAC\_Access.c. |
### Boot
| File type | Description |
| --- | --- |
| QUP v3 serial engine configuration | To configure the QUP v3 serial engine in the boot subsystem for
I2C, and GPIO for the I2C software use case, see the following
filepaths: