mpc82g516a Megawin Technology, mpc82g516a Datasheet - Page 53

no-image

mpc82g516a

Manufacturer Part Number
mpc82g516a
Description
8-bit Microcontroller
Manufacturer
Megawin Technology
Datasheet

Available stocks

Company
Part Number
Manufacturer
Quantity
Price
Part Number:
mpc82g516aE
Manufacturer:
MEGAWIN
Quantity:
1 200
Part Number:
mpc82g516aF
Manufacturer:
MEGAWIN
Quantity:
20 000
12.1.4 Using Timer 1 to Generate Baud Rates
When Timer 1 is used as the baud rate generator (T2CON.RCLK=0, T2CON.TCLK=0), the baud rates in Modes
1 and 3 are determined by the Timer 1 overflow rate and the value of SMOD as follows:
The Timer 1 interrupt should be disabled in this application. The Timer itself can be configured for either “timer” or
“counter” operation, and in any of its 3 running modes. In the most typical applications, it is configured for “timer”
operation, in the auto-reload mode (high nibble of TMOD = 0010B). In that case the baud rate is given by the
formula:
One can achieve very low baud rates with Timer 1 by leaving the Timer 1 interrupt enabled, and configuring the
Timer to run as a 16-bit timer (high nibble of TMOD=0001B), and using the Timer 1 interrupt to do a 16-bit
software reload.
Table 12-1 & Table 12-2 list various commonly used baud rates and how they can be obtained from Timer 1 in its
8-Bit Auto-Reload Mode.
Table 12-1. Timer 1 Generated Commonly Used Baud Rates @ Fosc=11.0592MHz
53
Baud Rate
115200
14400
19200
38400
57600
1200
1800
2400
4800
7200
9600
300
600
Mode 1, 3 Baud Rate =
Mode 1, 3 Baud Rate =
Where, n=12 if T1X12=0; n=1 if T1X12=1.
SMOD=0
160
208
232
240
244
250
252
253
254
-
-
-
-
2
T1X12=0
2
SMOD
SMOD
32
32
MPC82G516A Data Sheet
x (Timer 1 Overflow Rate)
x
SMOD=1
TH1, the Reload Value
n x (256-TH1)
160
208
224
232
244
248
250
252
253
255
64
-
-
Fosc
(Note: T1X12 bit is in AUXR2 register.)
SMOD=0
112
184
208
220
232
238
247
250
253
64
-
-
-
T1X12=1
SMOD=1
112
160
184
208
220
238
244
250
-
-
-
-
-
MEGAWIN

Related parts for mpc82g516a