Rainbow-electronics AT89LP214 Manual de usuario Pagina 40

  • Descarga
  • Añadir a mis manuales
  • Imprimir
  • Pagina
    / 90
  • Tabla de contenidos
  • MARCADORES
  • Valorado. / 5. Basado en revisión del cliente
Vista de pagina 39
40
3538A–MICRO–7/06
AT89LP213/214 [Preliminary]
17.2 Baud Rates
The baud rate in Mode 0 is fixed as shown in the following equation:
The baud rate in Mode 2 depends on the value of the SMOD1 bit in Special Function Register
PCON.7. If SMOD1 = 0 (the value on reset), the baud rate is 1/32 of the oscillator frequency. If
SMOD1 = 1, the baud rate is 1/16 of the oscillator frequency, as shown in the following equation:
17.2.1 Using Timer 1 to Generate Baud Rates
The Timer 1 overflow rate determines the baud rates in Modes 1 and 3. When Timer 1 is the
baud rate generator, the baud rates are determined by the Timer 1 overflow rate and the value
of SMOD1 according to the following equation:
The Timer 1 interrupt should be disabled in this application. The Timer itself can be configured
for either timer or counter operation in any of its 3 running modes. In the most typical applica-
tions, it is configured for timer operation in auto-reload mode (high nibble of TMOD = 0010B). In
this case, the baud rate is given by the following formula:
Programmers can achieve very low baud rates with Timer 1 by configuring the Timer to run as a
16-bit auto-reload timer (high nibble of TMOD = 0001B). In this case, the baud rate is given by
the following formula.
Table 17-2 lists commonly used baud rates and how they can be obtained from Timer 1.
Mode 0 Baud Rate
Oscillator Frequency
2
------------------------------------------------------ -=
Mode 2 Baud Rate
2
SMOD1
32
--------------------
(Oscillator Frequency)×=
Table 17-2. Commonly Used Baud Rates Generated by Timer 1 (TPS = 0000B)
Baud Rate f
OSC
(MHz) SMOD1
Timer 1
C/T Mode Reload Value
Mode 0: 1 MHz 2 X X X X
Mode 2: 375K 12 0 X X X
62.5K 12 1 0 2 F4H
19.2K 11.059 1 0 2 DCH
9.6K 11.059 0 0 2 DCH
4.8K 11.059 0 0 2 B8H
2.4K 11.059 0 0 2 70H
1.2K 11.059 0 0 1 FEE0H
137.5 11.986 0 0 1 F55CH
110 6 0 0 1 F958H
110 12 0 0 1 F304H
Modes 1, 3
Baud Rate
2
SMOD1
32
--------------------
(Timer 1 Overflow Rate)×=
Modes 1, 3
Baud Rate
2
SMOD1
32
--------------------
Oscillator Frequency
256 TH1()[]
------------------------------------------------------ -
1
TPS
1+
--------------------
××=
Modes 1, 3
Baud Rate
2
SMOD1
32
--------------------
Oscillator Frequency
256
R
H1,RL1()[]
------------------------------------------------------ -
×
1
TPS
1+
--------------------
×=
Vista de pagina 39
1 2 ... 35 36 37 38 39 40 41 42 43 44 45 ... 89 90

Comentarios a estos manuales

Sin comentarios