M16C/62P Group (M16C/62P, M16C/62PT)
17. Serial Interface
Rev.2.41
Jan 10, 2006
Page 196 of 390
REJ09B0185-0241
17.1.1.7
CTS/RTS Function
When the CTS function is used transmit and receive operation start when “L” is applied to the CTSi/RTSi (i=0
to 2) pin. Transmit and receive operation begins when the CTSi/RTSi pin is held “L”. If the “L” signal is
switched to “H” during a transmit or receive operation, the operation stops before the next data.
When the RTS function is used, the CTSi/RTSi pin outputs on “L” signal when the microcomputer is ready to
receive. The output level becomes “H” on the first falling edge of the CLKi pin.
•
CRD bit in UiC0 register = 1 (disable CTS/RTS of UART0)
CTSi/RTSi pin is programmable I/O function
•
CRD bit = 0, CRS bit = 0 (CTS function is selected)
CTSi/RTSi pin is CTS function
•
CRD bit = 0, CRS bit = 1 (RTS function is selected)
CTSi/RTSi pin is RTS function
17.1.1.8
CTS/RTS Separate Function (UART0)
This function separates CTS0/RTS0, outputs RTS0 from the P6_0 pin, and accepts as input the CTS0 from the
P6_4 pin. To use this function, set the register bits as shown below.
•
CRD bit in U0C0 register = 0 (enable CTS/RTS of UART0)
•
CRS bit in U0C0 register = 1 (output RTS of UART0)
•
CRD bit in U1C0 register = 0 (enable CTS/RTS of UART1)
•
CRS bit in U1C0 register = 0 (input CTS of UART1)
•
RCSP bit in UCON register = 1 (inputs CTS0 from the P6_4 pin)
•
CLKMD1 bit in UCON register = 0 (CLKS1 not used)
Note that when using the CTS/RTS separate function, CTS/RTS of UART1 separate function cannot be used.
Figure 17.18
CTS/RTS Separate Function
Microcomputer
TXD0 (P6_3)
RXD0 (P6_2)
IN
OUT
CTS
RTS
CTS0 (P6_4)
RTS0 (P6_0)
IC
CLK0 (P6_1)
CLK
http://www.xinpian.net
提供单片机解密、IC解密、芯片解密业务
010-62245566 13810019655