Sonic Alert msm83c154s, msm80154s, msm85c154hvs user manual 3.3.3 16-bit baud rate generator mode

Models: msm83c154s msm85c154hvs msm80154s

1 378
Download 378 pages 26.51 Kb
Page 102
Image 102

XTAL 1

 

 

12

 

S3

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

C/ T2

INTERNAL SPECIFICATIONS

RCLK=0

 

 

 

TCLK=0

 

 

 

CP/ RL2=1

 

 

 

Q0------Q7

Q0------Q7

TL2

C

TH2

C

8 BIT

 

8 BIT

 

T2

[PORT 1.0]

T2EX

[PORT 1.1]

TR2

DETECTOR

DETECTOR

EXEN2

 

RCAP2L

 

 

 

 

 

RCAP2H

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

DETECTOR

 

 

 

 

 

TF2

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

TIMER 2

 

 

 

 

 

 

 

DETECTOR

 

EXF2

 

 

 

 

INTERRUPT

 

 

 

 

 

 

 

 

 

 

 

 

 

 

Figure 4-21 Timer/counter 2 16-bit capture mode circuit

4.5.3.3.3 16-bit baud rate generator mode

The 16-bit baud rate generator mode is set by making the connections shown in Figure 4-22 with the following timer 2 control register (T2CON) bit conditions, viz.

RCLK+TCLK=1.

Timer/counter 2 commences to operate in the following way when 16-bit baud rate generator mode is set.

Timer/counter 2 is put into 16-bit auto reload mode. When timer/counter 2 generates a carry signal, the reload data in the RCAP2L and RCAP2H registers is preset in the timer/counter

2 TL2 and TH2 and the timer/counter commences to count from that preset value. The carry signal is passed to a serial port.

The timer/counter 2 carry signal activates the serial port receive circuit when RCLK 1, and activates the transmit circuit when TCLK=1. Note, however, that the serial port can use these clocks only when the serial port is in mode 1 and 3.

When in this mode, the timer/counter 2 carry signal is not set in internal timer flag 2 (TF2). But since the change in level (from “1” to “0”) of the signal applied to the T2EX pin (bit 1 of port 1) is set in external timer flag 2, the T2EX pin can be used for ordinary external interrupt input pin. If an interrupt routine is commenced, the EXF2 flag must be reset to “0” by software. Since timer/counter 2 is operated at 1/2 of the XTAL1·2 clock if the internal clock is used in this mode, only undefined data will be read from the timer/counter 2 TL2 and TH2 by software. Correct data, however, is read from the RCAP2L and RCAP2H registers.

95

Page 102
Image 102
Sonic Alert msm83c154s, msm80154s 3.3.3 16-bit baud rate generator mode, Timer/counter 2 16-bit capture mode circuit