Serial Operation
Universal Asynchronous Receiver/Transmitter 1 and 2 14-3
Figure 14-2. NRZ ASCII “A” Character with Odd Parity
14.2.2 IrDA Mode
Infrared (IrDA) mode uses character frames as NRZ mode does, but, instead of driving ones and zeros for
a full bit-time period, zeros are transmitted as three-sixteenth (or less) bit-time pulses, and ones remain
low. The polarity of transmitted pulses and expected receive pulses can be inverted so that a direct
connection can be made to external IrDA transceiver modules that uses active low pulses. Figure14-3
illustrates a character in IrDA mode.
Figure 14-3. IrDA ASCII “A” Character with Odd Parity
14.2.3 Serial Interface Signals
The UART module has five signals that are used to communicate with ext ernal UART-c ompatible devices.
The pins of both UART modules operate identically. Exceptions in pin an d regist er nomencl ature a re noted
in the following descriptions:
TXD1/TXD2—The RS-232 Transmit Data signal, which is multiplexed with PE5 in U ART 1 (PJ5
in UART 2), is the RS-232 transmitter serial output. This pin connects to standard RS-232 or
infrared transceiver modules. While the UAR T is i n NRZ mode, normal data is output with “marks”
transmitted as logic high and “spaces” transmitted as logic low. In IrDA mode, this pin, which is a
configurable narrow pulse, is output for each zero bit that is transmitted.
• CTS1/CTS2—The Clear to Send signal, which is multiplexed with PE7 (PJ7 in UART 2), is an
active low input used for transmitter flow control. The tra nsmitter wait s unti l this signa l is as sert ed
(low) before it starts transmitting a character. If this signal is negated while a character is being
transmitted, the character will be completed, but no additional characters are transmitted until this
signal is asserted again. The current value of this pin can be read in the CTSx STAT bit of the
corresponding UART transmitter (UTX) register.
NOTE:
If the NOCTSx bit of the UTX register is set, th e transmitter sends a
character whenever a character is ready to be transmitted. The CTSx pin
can be programmed to post an interrupt on rising and falling edges if the
CTSD bit is set in the corresponding UART control (USTCNT) register.
Start Bit
Bit 0
Bit 1
Bit 2
Bit 3
Bit 4
Bit 5
Bit 6
Bit 7
Parity Bit
Stop Bit
Start Bit
Bit 0
Bit 1
Bit 2
Bit 3
Bit 4
Bit 5
Bit 6
Bit 7
Parity Bit
Stop Bit