Fujitsu MB90390 Series Hardware Manual page 417

Table of Contents

Advertisement

UART2, UART3 as LIN slave
In LIN slave mode UART2, UART3 has to synchronize to the master's baud rate. If Reception is disabled
(RXE = 0) but LIN break Interrupt is enabled (LBIE = 1) UART2, UART3 will generate a reception
interrupt, if a synchronization break from the LIN master is detected, and indicates it with the LBD flag of
the ESCR2/ESCR3. Writing "0" to this bit clears the reception interrupt request. The LIN slave may need
to calculate the baud rate from the synch field. In this case, the time between the first falling edge to the
fifth falling edge of the synch field is measured by the input capture module. For this purpose, the input
capture module is connected to the LIN-UART2, UART3 with an internal signal. This internal signal
changes from "0" to "1" at the first falling edge then "1" to "0" at the fifth falling edge. Therefore the input
capture module should be set to detect both rising and falling edge. Also the input signal from the LIN-
UART2, UART3 should be selected. The time measured by the input capture module represents 8 times of
the baud rate clock cycle.
Therefore, baud rate setting value is summarized as follows:
without free run timer overflow : BGR value = {(b-a)×Fe/(8×φ)}-1
with free run timer overflow
Note:
Do not set the baud rate if the BGR value newly calculated from the Synch field in LIN slave mode
as above has an error from the baud rate by ±15% or more.
For the correspondence between other UARTs and ICUs, see Section "13.3 16-bit Free-run Timer" and
Section "13.5 Input Capture".
: BGR value = {(max+b-a)×Fe/(8×φ)}-1
where max is the free run timer maximum value at the overflow occurs.
where a is the value of the ICU data register after the first Interrupt
where b is the value of the ICU data register after the second Interrupt
where φ is the machine clock frequency (MHz).
where Fe is the external clock frequency (MHz). When the internal baud rate generator is used
(EXT=0), it calculates as Fe=φ.
CHAPTER 20 UART2, UART3
389

Advertisement

Table of Contents
loading

Table of Contents