18-4
MCF5249UM
MOTOROLA
I2C Protocol
18.4.3
DATA TRANSFER
Once successful slave addressing is achieved, the data transfer can proceed on a byte-by-byte basis in
the direction specified by the R/W bit sent by the calling master.
Each data byte is 8 bits long. Data can be changed only while SCL is low and must be held stable while
SCL is high, as shown in
Figure 18-2. There is one clock pulse on SCL for each data bit with the MSB
being transferred first. Each byte of data must be followed by an acknowledge bit, which is signalled from
the receiving device by pulling the SDA low at the ninth clock. One complete data byte transfer needs nine
clock pulses.
If the slave receiver does not acknowledge the master, the SDA line must be left high by the slave. The
master can then generate a stop signal to abort the data transfer or a start signal (repeated start) to start a
new calling sequence.
If the master receiver does not acknowledge the slave transmitter after a byte transmission, it means “end
of data'’ to the slave. The slave releases the SDA line for the master to generate a STOP or START signal.
18.4.4
REPEATED START SIGNAL
As shown in
Figure 18-2, a repeated START signal is a START signal generated without first generating a
STOP signal to terminate the communication. The master uses this method to communicate with another
slave or with the same slave in a different mode (transmit/receive mode) without releasing the bus.
18.4.5
STOP SIGNAL
The master can terminate the communication by generating a STOP signal to free the bus. However, the
master can generate a START signal followed by a calling command without generating a STOP signal
first. This is called repeated START. A STOP signal is defined as a low-to-high transition of SDA while SCL
Note: A master can generate a STOP even if the slave has made an acknowledgment at
which point the slave must release the bus.
18.4.6
ARBITRATION PROCEDURE
I2C is a true multimaster bus that allows connection to more than one master. If two or more masters try to
simultaneously control the bus, a clock synchronization procedure determines the bus clock, for which the
low period is equal to the longest clock low period and the high is equal to the shortest one among the
devices. A data arbitration procedure determines the relative priority of the contending masters. A bus
master loses arbitration if it transmits logic 1 while another master transmits logic 0. The losing masters
immediately switch over to slave-receive mode and stop driving SDA output. In this case, the transition
from master to slave mode does not generate a STOP condition. Meanwhile, hardware sets MBSR[IAL] to
indicate loss of arbitration.
18.4.7
CLOCK SYNCHRONIZATION
Because wire-AND logic is performed on SCL line, a high-to-low transition on SCL line affects all the
devices connected on the bus. The devices start counting their low period when the master drives the SCL
line low. Once a device clock has gone low, it holds the SCL line low until the clock high state is reached.
However, the change of low to high in the MCF5249 clock may not change the state of the SCL line if
another device clock is still within its low period. Therefore, synchronized clock SCL is held low by the
device with the longest low period. Devices with shorter low periods enter a high wait state during this time
(see
Figure 18-3). When all devices concerned have counted off their low period, the synchronized clock
F
re
e
sc
a
le
S
e
m
ic
o
n
d
u
c
to
r,
I
Freescale Semiconductor, Inc.
For More Information On This Product,
Go to: www.freescale.com
n
c
..
.