UART Baud Rate Calculator
Calculate UART baud rate or divisor/BRR from your clock settings. Includes bit time, frame time, and percent error.
How to Use
- Choose a mode: Clock → Baud (given divisor) or Clock → Divisor (given target baud).
- Enter your peripheral clock (Hz / kHz / MHz) and select an oversampling mode (commonly 16× or 8×).
- Optionally set data bits, parity, and stop bits to estimate frame time.
- Open Show Work for the formulas and the exact math used.
- Typical formula (generic): baud ≈ fclk / (oversample × divisor)
- Oversample: common UART modes are 16× and 8× (MCU-dependent)
- Frame bits: start(1) + data(5–9) + parity(0/1) + stop(1/1.5/2)
Show Work (step-by-step)
Reference
This tool uses a generic baud divider model:
baud = f_clk / (OS × divisor)
- Compute divisor:
divisor = f_clk / (OS × baud_target) - Compute actual baud:
baud_actual = f_clk / (OS × divisor_used) - Percent error:
%error = (baud_actual − baud_target) / baud_target × 100 - Frame bits:
1 start + data + parity(0/1) + stop - Bit time:
t_bit = 1 / baud_actual - Frame time:
t_frame = frame_bits × t_bit
FAQ
What baud error is “okay”?
It depends on both ends (clock accuracy, oversampling, line conditions). Small errors often work; larger errors can break framing. Use this tool to quantify error and then verify against your device datasheets and requirements.
Why does my MCU datasheet not match this divisor?
Many MCUs use mantissa/fraction fields (or alternate formulas). This tool provides a clean baseline model and shows the math so you can map it to your specific BRR format.
Does parity change the baud rate?
No. Parity changes frame length (more bits per character), so it changes frame time and throughput, not the baud itself.
Tool Info
Last updated:
Updates may include additional MCU-oriented presets, edge-case handling, and export improvements.