USART Drivers

Four driver variants are available for the USART: Synchronous, Asynchronous, RTOS, and DMA.

  • USART Synchronous Driver: The driver supports polling for hardware changes, the functionality is synchronous to the main clock of the MCU.

  • USART Asynchronous Driver: The driver supports a callback handler for the IRQ caused by hardware state changes. The functionality is asynchronous to the main clock of the MCU.

  • USART RTOS Driver: The driver supports a Real-Time operating system, i.e. is thread safe.

  • USART DMA Driver: The driver uses a DMA system to transfer and receive data between the USART and a memory buffer. It supports a callback handler for the IRQ caused by hardware state changes. The functionality is asynchronous to the main clock of the MCU.

USART Basics and Best Practice

The universal synchronous and asynchronous receiver and transmitter (USART) is normally used to transfer data from one device to the other.

The USART provides one full duplex universal synchronous asynchronous serial link. Data frame format is widely programmable (data length, parity, number of stop bits) to support a maximum of standards. The receiver implements parity error, framing error, and overrun error detection. The receiver timeout enables handling variable-length frames and the transmitter timeguard facilitates communications with slow remote devices. Multidrop communications are also supported through address bit handling in reception and transmission.