14.3.4 I2C Module START and STOP Conditions
START and STOP conditions can be generated by the I2C module when the module is configured to be a master
on the I2C bus. As shown in
• The START condition is defined as a high-to-low transition on the SDA line while SCL is high. A master drives
this condition to indicate the start of a data transfer.
• The STOP condition is defined as a low-to-high transition on the SDA line while SCL is high. A master drives
this condition to indicate the end of a data transfer.
SDA
SCL
START
condition (S)
condition (P)
STOP
Figure 14-8. I2C Module START and STOP Conditions
After a START condition and before a subsequent STOP condition, the I2C bus is considered busy, and the bus
busy (BB) bit of I2CSTR is 1. Between a STOP condition and the next START condition, the bus is considered
free, and BB is 0.
For the I2C module to start a data transfer with a START condition, the master mode bit (MST) and the START
condition bit (STT) in I2CMDR must both be 1. For the I2C module to end a data transfer with a STOP condition,
the STOP condition bit (STP) must be set to 1. When the BB bit is set to 1 and the STT bit is set to 1, a repeated
START condition is generated. For a description of I2CMDR and its bits (including MST, STT, and STP), see
.
The I2C peripheral cannot detect a START or STOP condition while it is in reset (IRS = 0). The BB bit will remain
in the cleared state (BB = 0) while the I2C peripheral is in reset (IRS = 0). When the I2C peripheral is taken out
of reset (IRS set to 1) the BB bit will not correctly reflect the I2C bus status until a START or STOP condition is
detected.
Follow these steps before initiating the first data transfer with I2C:
1. After taking the I2C peripheral out of reset by setting the IRS bit to 1, wait a period larger than the total time
taken for the longest data transfer in the application. By waiting for a period of time after I2C comes out of
reset, users can ensure that at least one START or STOP condition will have occurred on the I2C bus and
been captured by the BB bit. After this period, the BB bit will correctly reflect the state of the I2C bus.
2. Check the BB bit and verify that BB = 0 (bus not busy) before proceeding.
3. Begin data transfers.
Not resetting the I2C peripheral in between transfers ensures that the BB bit reflects the actual bus status. If
users must reset the I2C peripheral in between transfers, repeat steps 1 through 3 every time the I2C peripheral
is taken out of reset.
Inter-Integrated Circuit Module (I2C)
SPRUH18I – JANUARY 2011 – REVISED JUNE 2022
TMS320x2806x Microcontrollers
843
Copyright © 2022 Texas Instruments Incorporated
Summary of Contents for TMS320 2806 Series
Page 2: ......