Inter-Integrated Circuit Bus Controller Module (I
2
C)
MPC5510 Microcontroller Family Reference Manual, Rev. 1
27-8
Freescale Semiconductor
Preliminary
27.3.2.3
I
2
C Bus Control Register (IBCR)
Offset: 0x0002
Access: Read/write any time
0
1
2
3
4
5
6
7
R
MDIS
IBIE
MS
TX
NOACK
0
DMAEN
0
W
RSTA
Reset
1
0
0
0
0
0
0
0
Figure 27-6. I
2
C Bus Control Register (IBCR)
Table 27-5. IBCR Field Descriptions
Field
Description
MDIS
Module Disable. This bit controls the software reset of the entire I
2
C bus module.
0 The I
2
C bus module is enabled. This bit must be cleared before any other IBCR bits have any effect.
1 The module is reset and disabled. This is the power-on reset situation. When high, the interface is held in reset,
but registers can be accessed.
Note: If the I
2
C bus module is enabled in the middle of a byte transfer, the interface behaves as follows: slave mode
ignores the current transfer on the bus and starts operating when a subsequent start condition is detected.
Master mode will not be aware that the bus is busy; therefore, if a start cycle is initiated, then the current bus
cycle may become corrupt. This ultimately results in the current bus master or the I
2
C bus module losing
arbitration, after which, bus operation returns to normal.
IBIE
I-Bus Interrupt Enable.
0 Interrupts from the I
2
C bus module are disabled. This does not clear any currently pending interrupt condition.
1 Interrupts from the I
2
C bus module are enabled. An I
2
C bus interrupt occurs provided the IBIF bit in the status
register is also set.
MS
Master/Slave Mode Select. This bit is cleared on reset. When this bit is changed from 0 to 1, a START signal is
generated on the bus and the master mode is selected. When this bit is changed from 1 to 0, a STOP signal is
generated and the operation mode changes from master to slave. A STOP signal should be generated if only the
IBIF flag is set. MS is cleared without generating a STOP signal when the master loses arbitration.
0 Slave mode.
1 Master mode.
TX
Transmit/Receive Mode Select. This bit selects the direction of master and slave transfers. When addressed as a
slave this bit must be set by software according to the SRW bit in the status register. In master mode this bit must
be set according to the type of transfer required. Therefore, for address cycles, this bit is always high.
0 Receive.
1 Transmit.
NOACK
Data Acknowledge Disable. This bit specifies the value driven onto SDA during data acknowledge cycles for both
master and slave receivers. The I
2
C module will always acknowledge address matches, provided it is enabled,
regardless of the value of NOACK. Values written to this bit are used only when the I
2
C Bus is a receiver, not a
transmitter.
0 An acknowledge signal will be sent out to the bus at the 9th clock bit after receiving one byte of data.
1 No acknowledge signal response is sent (i.e., acknowledge bit = 1).
RSTA
Repeat Start. Writing a 1 to this bit generates a repeated START condition on the bus, provided it is the current bus
master. This bit is always read as a low. Attempting a repeated start at the wrong time, if the bus is owned by another
master, results in loss of arbitration.
0 No effect.
1 Generate repeat start cycle.