
1-130
dUnde
Specifications in this manual are tentative and subject to change
Rev. G
UART2 in I
2
C Mode
MITSUBISHI MICROCOMPUTERS
M30222 Group
SINGLE-CHIP 16-BIT CMOS MICROCOMPUTER
UART2 in I
2
C Mode
The UART2 special mode register (address 0377
16
) is used to control UART2 in various ways.
Figure 1.104 shows the UART2 special mode register. Setting the I
2
C mode select bit (bit 1 of
U2SMR) to "1" selects I
2
C mode.
Table 1.41 shows the relation between the I
2
C mode select bit and respective control workings.
Since this function uses clock-synchronous serial I/O mode, set this bit to “0” in UART mode.
Table 1.41. Features in I
2
C mode
Function
Normal mode
I
2
C mode (Note 1)
Source for interrupt number 15 (Note 2)
UART2 transmission
No acknowledgment detection (NACK)
Source for interrupt number 16 (Note 2)
UART2 reception
Start condition detection or stop
condition detection
UART2 transmission output delay
Not delayed
Delayed
P7
0
at the time when UART2 is in use
TxD
2
(output)
SDA (input/output) (Note 3)
P7
1
at the time when UART2 is in use
RxD
2
(input)
SCL (input/output)
P7
2
at the time when UART2 is in use
CLK
2
P7
2
DMA1 factor at the time when 1 1 0 1 is assigned
to the DMA request factor selection bits
UART2 reception
Acknowledgment detection (ACK)
Noise filter width
15ns
Reading the terminal when 0 is
assigned to the direction register
50ns
Reading the terminal regardless of the
value of the direction register
Reading P7
1
1
2
3
4
5
6
7
8
9
Note 1: Make the settings given below when I
2
C mode is in use.
Set 0 1 0 in bits 2, 1, 0 of the UART2 transmission/reception mode register.
Disable the RTS/CTS function. Choose the MSB First function.
Note 2: Follow the steps given below to switch from a factor to another.
1. Disable the interrupt of the corresponding number.
2. Switch from one source to another.
3. Reset the interrupt request flag of the corresponding number.
4. Set an interrupt level of the corresponding number.
Note 3: Set an initial value of SDA transmission output when serial I/O is invalid.
Source for interrupt number 10 (Note 2)
Bus collision detection
Acknowledgment detection (ACK)
10
Initial value of UART2 output
H level (when 0 is assigned to
the CLK polarity select bit)
The value set in latch P7
0
when the port is
selected
11