Budget total stop-bit drift when running UART without a crystal
Eliminating an external quartz crystal saves BOM cost and two MCU pins, but internal RC oscillators drift with temperature and supply voltage (commonly ±1% factory-calibrated, up to ±3–10% across extreme voltage/temperature corners).
At 8 MHz and 9,600 bps, UBRR = 51 introduces only +0.16% divider error, leaving almost the entire ±2% budget for RC drift—whereas 38,400 bps adds +0.16% or 57,600 bps adds −3.55% and fails rapidly.
Formulas
Osc error (%) = ppm ÷ 10,000 (10,000 ppm = 1.0%)Worst-case combined = |Divider Error %| + 2 × Osc Error %Stop-bit drift = Combined % × 9.5 bits (8N1)
Worked example
At 8 MHz with ±1% (10,000 ppm) RC tolerance and 9,600 bps, UBRR = 51 gives +0.160% divider error and 20.5% worst-case stop-bit drift (Pass). At ±3% RC, stop-bit drift exceeds 58% (Fail).