English
Language : 

W78IRD2 Datasheet, PDF (23/76 Pages) Winbond – 8-BIT MICROCONTROLLER
W78IRD2
BIT NAME
FUNCTION
Timer 2 overflow flag: If RCLK and TCLK are 0, this bit is set when Timer 2
7
TF2
overflows or when the count is equal to the value in the capture register in down-
count mode. This bit can also be set by software, and it can only be cleared by
software.
Timer 2 External Flag: When Timer 2 is in either capture or auto-reload mode
6
EXF2
and DCEN is 0, a negative transition on the T2EX pin (P1.1) and EXEN2=1 sets
this flag. This flag can also be set by software. Once set, this flag generates a
Timer-2 interrupt, if enabled, and it must be cleared by software.
Receive Clock Flag: Set this bit to force Timer 2 into baud-rate generator mode
when receiving data on the serial port in modes 1 or 3.
5
RCLK 1 = Timer 2 overflow is the time base.
0 = Timer 1 overflow is the time base.
Transmit clock Flag: Set this bit to force Timer 2 into baud-rate generator mode
when transmitting data on the serial port in modes 1 or 3.
4
TCLK 1 = Timer 2 overflow is the time base.
0 = Timer 1 overflow is the time base.
Timer 2 External Enable: If Timer 2 is not in baud-rate generator mode (see RCLK
3 EXEN2 and TCLK above), set this bit to allow a negative transition on the T2EX pin to
capture/reload Timer 2 counter.
Timer 2 Run Control:
2
TR2 1 = Enable Timer 2.
0 = Disable Timer 2, which preserves the current value in TH2 and TL2.
Counter/Timer select:
1
C/T2 0 = Timer 2 operates as a timer at a speed controlled by T2M (CKCON.5)
1 = Timer 2 counts negative edges on the T2EX pin.
Capture/Reload Select: If EXEN2 is set to 1, this bit determines whether the
capture or auto-reload function is activated.
0 = auto-reload when timer 2 overflows or a falling edge is detected on T2EX
0 CP/RL2
1 = capture each falling edge is detected on T2EX
If either RCLK or TCLK is set, this bit has no function, as Timer 2 runs in auto-
reload mode.
Timer 2 Mode
Bit:
7
6
5
4
3
-
-
-
-
-
Mnemonic: T2MOD Address: C9h
2
1
0
-
T2OE DCEN
- 23 -
Publication Release Date: October 2, 2006
Revision A7