![](http://datasheet.mmic.net.cn/230000/79RC32438-200BB_datasheet_15568909/79RC32438-200BB_400.png)
IDT I2C Bus Interface
I2C Bus Master Interface
79RC32438 User Reference Manual
15 - 6
November 4, 2002
Notes
The I
2
C bus SCL and SDA signals are wired-AND, allowing the clock signal to be used as a synchroni-
zation mechanism. A device on the I
2
C bus can slow down, or stop, the I
2
C bus clock at any point by
extending the low period of the clock.
2
This can be done after each bit, or after a complete operation is
performed.
2
Thus, the speed of the master is automatically adapted to the operating rate of the slowest
device. This is illustrated in Figure 15.6.
2
Figure 15.6 Using the I
2
C Bus Clock (SCL) to Adapt the Operating Rate
When a command is written to the I2CMCMD register, the specified action is initiated on the I
2
C bus. For
commands other than NOP, this consists of generating the I
2
C bus clock (SCL) and possibly driving the I
2
C
bus data pin (SDA).
2
The completion of the command is signaled to the CPU by setting the done (D) bit in
the I2CMS register.
2
Depending on the command, other status bits in this register may also become
valid.
2
When the done bit is set, the master interface holds the SCL signal low, allowing the CPU core to
respond to the received status information and issue the next command
1
. All of the status bits in the I2CMS
register,
2
including the done bit,
2
are automatically cleared and SCL signal is released when a command is
written to the I2CMCMD
2
register.
2
The
2
Read Data (RD), Read Data with Acknowledge (RDACK), Write Data (WD), and Write Data with
Acknowledge (WDACK) commands all participate in I
2
C bus arbitration. When one of these commands is
issued, the master interface observes the state of SDA. Arbitration is lost when a master I
2
C bus interfaces
transmits a high value but observes a low value on the SDA signal. When this occurs the master I
2
C bus
0110
WD
Write Data
. Transmit 8-bits of data from the I2CDO register onto the I
2
C bus.
When this command completes the D bit is set and the NA, LA, and ERR status
bits are valid.
0111
WDACK
Write Data and Acknowledge. (This command is for debug purposes only.)
Transmit 8-bits of data from the I2CDO register onto the I
2
C bus. After the data
has been transmitted, generate an acknowledge. When this command com-
pletes the D bit is set and the NA, LA, and ERR status bits are valid.
1000 through
1111
Reserved
Same effect as NOP.
1.
This is true for all commands except the STOP command. At the completion of the STOP command, the D bit is
set, the I
2
C bus is released by tri-stating the SDA and SCL signals, and the master goes into an idle state.
Command
Encoding
Mnemonic
Description
Table 15.2 I2C Bus Master Interface Commands (Part 2 of 2)
I2CPCLK
SCL
1
5
6
1.
A slave becomes not-ready, so it pulls SCL low. Since SCL is wired-AND, it is held low as long as the slave is not-ready.
The I
2
C bus master is suspended.
Slave becomes ready and releases SCL. This allows the clock to progress.
A device may pull SCL low even before I2CPCLK (the internally generated I
2
C bus prescalar clock) goes low. This may
occur for example during I
2
C bus arbitration when multiple masters drive the bus.
An external device can release SCL at any point. The master interface must make sure that “runt” clocks are not gener-
ated which have a period smaller than that programmed in the I2CCP register. This may mean that the master interface
stretches the clock and waits for the next rising edge of I2CPCLK.
A slave becomes not-ready.
A slave becomes ready.
2.
3.
4.
5.
6.
2
3
4