Baud rate calculator for Xmega

normal/double clock mode:
 
This baud rate calculator computes from fcpu , the desired baud rate and the clock mode, if possible, the value of BSEL for all possible values of scale factor BSCALE.

Result for fcpu = 2 MHz , baud rate = 115200 bps and normal clock speed

BSCALE BSEL calculated BSEL baud rate calculated error
-710.88911115108-0.1%
-65.44451159420.6%
-52.7223114286-0.8%
-41.36111176472.1%
-30.6811111111-3.5%
-20.34001250008.5%
-10.17001250008.5%
00.08501250008.5%
1-0.457062500-45.7%
2-0.729-1
3-0.864-1
4-0.932-1
5-0.966-1
6-0.983-1
7-0.992-1
legend
OK error 1%
probably OK error 2%
not OK error > 2%
    or
BSEL > 4095
    or
BSEL=0 and BSCALE≠0
    or
BSEL < 0