
Rev. 1.00
445 of 486
July 31, 2018
32-Bit Arm
®
Cortex
®
-M0+ MCU
HT32F50231/HT32F50241
21 Universal Synchronous
Asynchronous Receiver T
ransmitter (USART)
1
0
0
1
1
0
1
1
1
0
START
TX_Data
IrDA TX
Modulation
Signal
STOP
3/16 bit width
RX_Data
bit width
1
0
0
1
1
0
1
1
1
0
START
STOP
Data Frame
Data Frame
IrDA RX
Demodulation
Signal
Figure 168. IrDA Modulation and Demodulation
The IrDA mode provides two operation modes, one is the normal mode and the other is the low-
power mode.
IrDA Normal Mode
For the IrDA normal mode, the width of each transmitted pulse generated by the transmitter
modulator is specified as 3/16 of the baud rate clock period. The receiver pulse width for the IrDA
receiver demodulator is based on the IrDA receive debounce filter which is implement using an
8-bit down-counting counter. The debounce filter counter value is specified by the IrDAPSC field
in the IrDACR register. When a falling edge is detected on the receiver pin, the debounce filter
counter starts to count down, driven by the CK_USART clock. If a rising edge is detected on the
receiver pin, the counter stops counting and is reloaded with the IrDAPSC value. When a low
pulse falling edge on the receiver pin is detected and then before the debounce filter has counted
down to zero, a rising edge is also detected, then this low pulse will be considered as glitch noise
and will be discarded. If a low pulse falling edge appears on the receiver pin but no rising edge
is detected before the debounce counter reaches 0, then the input is regarded as a valid data “0”
for this bit duration. The IrDAPSC value must be set to be greater than or equal to 0x01, then the
IrDA receiver demodulation operation can function properly. The IrDAPSC value can be adjusted
to meet the USART baud rate setting to filter the IrDA received glitch noise of which the width is
smaller than the prescaler setting duration.
IrDA Low-Power Mode
In the IrDA low-power mode, the transmitted IrDA pulse width generated by the transmitter
modulator is not kept at 3/16 of the baud rate clock period. Instead, the pulse width is fixed and is
calculated by the following formula. The transmitted pulse width can be adjusted by the IrDAPSC
field to meet the minimum pulse width specification of the external IrDA Receiver device.