Motorola MCF5281 Calculating Baud Rates, Following sections describe how to calculate baud rates

Models: MCF5282 MCF5281

1 816
Download 816 pages 28.97 Kb
Page 493
Image 493

Operation

The system clock supplies an asynchronous clock source that is divided by 32 and then divided by the 16-bit value programmed in UBG1n and UBG2n. See Section 23.3.11, “UART Baud Rate Generator Registers (UBG1n/UBG2n).”

The choice of DTIN or system clock is programmed in the UCSR.

DTOUTn

On-Chip

 

 

 

 

 

DTINn

Timer Module

 

 

 

 

 

 

UART

 

 

UTXDn

Clocking sources programmed in UCSR

Tx Buffer

 

DTIN

 

x1

16-Bit

 

 

 

Prescaler

Divider

 

 

Tx

16-Bit

DTIN

 

x16

 

Prescaler

Divider

 

 

Rx

 

 

 

Clock

16-Bit

x32

 

Generator

Divider

Prescaler

URXDn

Rx Buffer

 

 

System

 

 

 

Clock

 

 

 

Figure 23-18. Clocking Source Diagram

NOTE

If DTINn is a clocking source for either the timer or UART, that timer module cannot use DTINn for timer capture.

23.5.1.2Calculating Baud Rates

The following sections describe how to calculate baud rates.

23.5.1.2.1System Clock Baud Rates

When the system clock is the UART clocking source, it goes through a divide-by-32 prescaler and then passes through the 16-bit divider of the concatenated UBG1n and UBG2n registers. The baud-rate calculation is as follows:

Baudrate =

SYSCLK

[---------------------------------32 x divider]

Using a 66MHz system clock and letting baud rate = 9600, then

MOTOROLA

Chapter 23. UART Modules

23-19

Page 493
Image 493
Motorola MCF5281 Calculating Baud Rates, Following sections describe how to calculate baud rates, System Clock Baud Rates