# UART Example

## Overview

This sample is a cross-loopback test for UART2 and UART3. It covers multiple baud rates, parity modes, stop-bit configurations, polling, buffer handling, and stress tests.

Source file: `src/rtsmart/examples/peripheral/uart/test_uart.c`

## Default Pin Mapping

- UART2: `TX=11`, `RX=12`
- UART3: `TX=50`, `RX=51`

## Key APIs

- `drv_uart_inst_create()` / `drv_uart_inst_destroy()`
- `drv_uart_set_config()` / `drv_uart_get_config()`
- `drv_uart_write()` / `drv_uart_read()`
- `drv_uart_poll()` / `drv_uart_recv_available()`
- `drv_uart_configure_buffer_size()`
- `drv_fpioa_set_pin_func()`

## Build and Run

```shell
cd src/rtsmart/examples/peripheral/uart
make
./test_uart
```

The sample has no command-line parameters.
