34.7.6 OOK Modulation and Demodulation
The USART has the capability to modulate the TXD line according to OOK modulation standard.
When the bit FLEX_US_MR.OOKEN=1 and the field FLEX_US_MR.USART_MODE is lower than 4, the TXD line is modulated if a logical 0 is transmitted, and not modulated if a logical 1 is transmitted.
The modulation frequency is adjusted by configuring the field FLEX_US_FIDI.OOKFREQ (see FLEX_US_FIDI) when the bit FLEX_US_MR.OOKEN=1.
The modulation frequency is calculated as per the following formula:
The selected clock can be defined in US_MR.USCLKS (see Baud Rate Generator).
When the bit FLEX_US_MR.OOKEN=1, the RXD line is demodulated. It is possible to configure a low-pass filter before entering the OOK demodulation logic. The low-pass filter is active when the field FLEX_US_IF.IRDA_FILTER is greater than 0 (see FLEX_US_IF).
If the bit US_MR.OOKEN=1, the RTS line is driven to 1 when a character is currently transmitted on the TXD line and the data bit being transmitted is 1. Therefore, during the stop bit the RTS line is driven to 1. It is driven to 0 when the internal state of the transmitter logic is in Idle mode.
