TM1100 Preliminary Data Book
Philips Semiconductors
15-4
PRELIMINARY INFORMATION
File: i2c.fm5, modified 7/25/99
transfer, the DSPCPU must refrain from writing to the
IIC_AR.COUNT bitfield until a message is complete.
Completion is indicated by the RBC bitfield decrementing
to zero.
15.4.4
IIC_CR Register
The I2C control register contains control information re-
quired for enabling I2C transfers. This register is used to
enable and clear interrupt sources which normally occur
during I2C operation. The four interrupt sources de-
scribed in the section on the IIC_SR register are enabled
and cleared through the IIC_CR register. The enable bit-
fields are:
GD_IEN — Enable for normal transfer complete
interrupt.
F_IEN — Enable for IIC_DR data service request
interrupt.
SANACK_IEN — Enable for slave address not
acknowledged interrupt. This is an error interrupt.
SDNACK_IEN — Enable for slave data not acknowl-
edged interrupt. An addressed slave receiver has
refused to accept the last byte transmitted to it. This
is handled as an error interrupt.
In addition to the interrupt enable bits, the IIC_CR con-
tains interrupt clear bits associated with each of the inter-
rupt sources in the IIC_SR register. These IIC_CR inter-
rupt clear bits are defined as:
CLRGDI — Clear bit for the GDI interrupt in the
IIC_SR register. Writing a ‘1’ to this bit clears the GDI
interrupt.
CLRFI — Clear bit for the FI interrupt in the IIC_SR
register. Writing a ‘1’ to this bit clears the FI interrupt.
CLRSANACKI — Clear bit for the SANACKI interrupt
in the IIC_SR register. Writing a ‘1’ to this bit clears
the SANACKI interrupt.
CLRSDNACKI — Clear bit for the SDNACKI interrupt
in the IIC_SR register. Writing a ‘1’ to this bit clears
the SDNACKI interrupt.
The remaining bitfield of the IIC_CR register is:
ENABLE — Master enable for I2C serial interface.
ENABLE must be set equal to ‘1’ to transfer any bits
from the I2C interface block. Writing a ‘0’ to the
ENABLE bit effectively resets the entire I2C interface,
including all status and interrupt ag bits. A transfer
in progress is aborted and the byte currently trans-
ferred is lost.
Note:
For writes, Reserved1, 2, 3 and 4 bitfields
MUST always be written with ‘0’s.
15.5
I2C SOFTWARE OPERATION MODE
I2C software operation mode is intended for use by soft-
ware I2C or similar algorithm implementations. In this
case, the SCL and SDA pins are fully controlled and ob-
served by software, and the hardware I2C interface is
disconnected from the SCL and SDA pins. Refer to
Figure 15-3 for a clarification of the principles involved.
Software mode is by default disabled after boot. Soft-
ware
mode
is
enabled
by
writing
a
‘1’
to
Table 15-7. IIC_CR Register
Bits
Field Name
Denition
31
GD_IEN
Enable for normal transfer complete
interrupt
30
F_IEN
Enable for IIC_DR data service
request interrupt.
29
SANACK_IEN
Enable for slave address not
acknowledged interrupt.
28
SDNACK_IEN
Enable for slave data not acknowl-
edged interrupt. An addressed slave
receiver has refused to accept the
last byte transmitted to it.
27:26
Reserved1
Always write ‘0’s to these bits. (See
Note1)
25
CLRGDI
Clear bit for the GDI interrupt in the
IIC_SR register. Writing a ‘1’ to this
bit clears the GDI interrupt.
24
CLRFI
Clear bit for the FI interrupt in the
IIC_SR register. Writing a ‘1’ to this
bit clears the FI interrupt.
23
CLRSANACKI
Clear bit for the SANACKI interrupt
in the IIC_SR register. Writing a ‘1’ to
this bit clears the SANACKI interrupt.
22
CLRSDNACKI
Clear bit for the SDNACKI interrupt
in the IIC_SR register. Writing a ‘1’ to
this bit clears the SDNACKI inter-
rupt.
21:6
Reserved2
Always write ‘0’s to these bits. (See
Note1)
10
SW_MODE_EN 0 (power-on/reset default) - Normal
I2C hardware operating mode..
1 - Enable software operating mode.
The I2C pins are entirely controlled
by user writes to the ‘sda_out’ and
‘scl_out’ register bits.
7
SDA_OUT
Enabled by sw_mode_en. This bit is
used by sw to manually control the
external i2c SDA data pin. Bit polar-
ity is:
1 = SDA pad pulled low
0 = SDA pad left open drain
6
SCL_OUT
Enabled by sw_mode_en. This bit is
used by sw to manually control the
external i2c SCL clock pin. Bit polar-
ity is:
1 = SCL pad pulled low
0 = SCL pad left open drain
5:2
Reserved3
Always write ‘0’s to these bits. (See
Note1)
1
Reserved4
Always write ‘0’s to these bits. (See
Note1)
0
ENABLE
I2C serial interface enable
Table 15-7. IIC_CR Register (Continued)
Bits
Field Name
Denition