
Rev. 1.00
474 of 576
January 28, 2022
32-Bit Arm
®
Cortex
®
-M0+ MCU
HT32F54231/HT32F54241/HT32F54243/HT32F54253
22 Universal Synchronous
Asynchronous Receiver T
ransmitter (USART)
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.
T
IrDA_L
= 3 ×
IrDAPSC / CK_USART
Note: T
IrDA_L
is the transmitted pulse width in the low-power mode.
The IrDAPSC field is the IrDACR prescaler value in the IrDA Control Register IrDACR.
The debounce behavior in the IrDA low-power receiving mode is similar to the IrDA normal mode.
For glitch detection, the low pulse of which the pulse width is shorter than 1 ×
(IrDAPSC / CK_
USART) should be discarded in the IrDA receiver demodulation. A valid low data is accepted if its
low pulse width is greater than 2 ×
(IrDAPSC / CK_USART) duration.
The IrDA physical layer specification specifies a minimum delay with a value of 10 ms between the
transmission and reception switch; and this IrDA receiver set-up time also should be managed by
the software.