Boot Assist Module (BAM) RM0046
824/936 Doc ID 16912 Rev 5
SCI autobaud rate feature operates by polling the LINFlex_RX pin for a low signal. The
length of time until the next low to high transition is measured using the System Timer
Module (STM) time base. This high-low-high transition is expected to be a zero byte: a start
bit (low) followed by eight data bits (low) followed by a stop bit (high).
Upon reception of a zero byte and configuration of the baud rate, an acknowledge byte is
returned to the host using the selected baud rate.
Time base is enabled at reception of first low bit, disabled and read at reception of next high
bit. Error introduced due to polling will be small (typically < 6 cycles).
The following equation gives the relation between baud rate and LINFlex register
configuration:
Equation 37
LDIV is an unsigned fixed point number and its mantissa is coded into 13 bits of the
LINFlex’s register LINIBRR.
From this equation and considering that a single UART transmission contains 9 bits, it is
possible to obtain the connection between time base measured by STM and LINIBB
register:
Equation 38
To minimize errors in baud rate, a large external oscillator frequency value and low baud
rate signal are preferred.
Example 17Baud rate calculation for 24 kBaud signal
Considering a 24 kbaud signal and the device operating with 20 MHz external frequency.
Over 9 bits the STM will measure: (9 × 20 MHz)/24 kbaud = 7497 cycles.
Error expected to be approximately ± 6 cycles due to polling.
Thus, LINIBB will be set to 52 (rounding required). This results in a baud rate of
24.038 kbaud. Error of < 0.2%.
To maintain the maximum deviation between host and calculated baud rate,
recommendations for the user are listed Table 444 .
Table 444. Maximum and minimum recommended baud rates
f
sys
=f
xtal
(MHz)
Max baud rate for guaranteed
<2.5% deviation
Min baud rate for guaranteed
<2.5% deviation
4
13.4 Kbit/s
(SBR = 19)
30 bit/s
(SBR = 8192)
8
26.9 Kbit/s
(SBR = 19)
60 bit/s
(SBR = 8192)
12
38.4 Kbit/s
(SBR = 20)
90 bit/s
(SBR = 8192)
LDIV
F
cpu
16 baudrate
-------------------------------------=
LINIBRR
timebase
144
--------------------------=