Chapter 33 Boot Assist Module (BAM)
MPC5602P Microcontroller Reference Manual, Rev. 4
Freescale Semiconductor
835
33.6.1.2.1
Choosing the host baud rate
The calculation of the UART baud rate from the length of the first 0 byte that is received, allows the
operation of the boot loader with a wide range of baud rates. However, to ensure proper data transfer, the
upper and lower limits have to be kept.
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:
Eqn. 33-1
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:
Eqn. 33-2
To minimize errors in baud rate, a large external oscillator frequency value and low baud rate signal are
preferred.
Example 33-3. Baud 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
.
LDIV
F
cpu
16 baudrate
---------------------------------
=
LINIBRR
timebase
144
-----------------------
=
Содержание SAFE ASSURE Qorivva MPC5601P
Страница 2: ...MPC5602P Microcontroller Reference Manual Rev 4 2 Freescale Semiconductor ...
Страница 4: ...MPC5602P Microcontroller Reference Manual Rev 4 4 Freescale Semiconductor ...
Страница 62: ...Chapter 2 MPC5602P Memory Map MPC5602P Microcontroller Reference Manual Rev 4 62 Freescale Semiconductor ...
Страница 104: ...Chapter 4 Clock Description MPC5602P Microcontroller Reference Manual Rev 4 104 Freescale Semiconductor ...
Страница 128: ...Chapter 6 Power Control Unit MC_PCU MPC5602P Microcontroller Reference Manual Rev 4 128 Freescale Semiconductor ...
Страница 272: ...Chapter 12 e200z0 and e200z0h Core MPC5602P Microcontroller Reference Manual Rev 4 272 Freescale Semiconductor ...
Страница 280: ...Chapter 14 Crossbar Switch XBAR MPC5602P Microcontroller Reference Manual Rev 4 280 Freescale Semiconductor ...
Страница 306: ...Chapter 16 Internal Static RAM SRAM MPC5602P Microcontroller Reference Manual Rev 4 306 Freescale Semiconductor ...
Страница 380: ...Chapter 17 Flash Memory MPC5602P Microcontroller Reference Manual Rev 4 380 Freescale Semiconductor ...
Страница 532: ...Chapter 21 LIN Controller LINFlex MPC5602P Microcontroller Reference Manual Rev 4 532 Freescale Semiconductor ...
Страница 578: ...Chapter 22 FlexCAN MPC5602P Microcontroller Reference Manual Rev 4 578 Freescale Semiconductor ...
Страница 708: ...Chapter 25 FlexPWM MPC5602P Microcontroller Reference Manual Rev 4 708 Freescale Semiconductor ...
Страница 742: ...Chapter 26 eTimer MPC5602P Microcontroller Reference Manual Rev 4 742 Freescale Semiconductor ...
Страница 760: ...Chapter 27 Functional Safety MPC5602P Microcontroller Reference Manual Rev 4 760 Freescale Semiconductor ...
Страница 782: ...Chapter 28 Fault Collection Unit FCU MPC5602P Microcontroller Reference Manual Rev 4 782 Freescale Semiconductor ...
Страница 788: ...Chapter 29 Wakeup Unit WKPU MPC5602P Microcontroller Reference Manual Rev 4 788 Freescale Semiconductor ...
Страница 798: ...Chapter 30 Periodic Interrupt Timer PIT MPC5602P Microcontroller Reference Manual Rev 4 798 Freescale Semiconductor ...
Страница 816: ...Chapter 32 Cyclic Redundancy Check CRC MPC5602P Microcontroller Reference Manual Rev 4 816 Freescale Semiconductor ...
Страница 848: ...Chapter 33 Boot Assist Module BAM MPC5602P Microcontroller Reference Manual Rev 4 848 Freescale Semiconductor ...
Страница 930: ...Chapter 36 Nexus Development Interface NDI MPC5602P Microcontroller Reference Manual Rev 4 930 Freescale Semiconductor ...