
Rev. 1.00
136 of ���
�an�a�� 1�� �01�
Standard 8051 8-Bit Flash MCU
HT85F2260/HT85F2270/HT85F2280
Timer/Event Counters 0, 1, 3
Mode 2 – 8-bit Auto-reload Counter/Timer Mode Operation
To select this mode, bits TnM1 and TnM0, should be set to “10” respectively. This function is
implemented by the 8-bit TLn and THn registers. The C/Tn bit is used to select the timer or counter
function. The Counter/Timer Run or Stop is controlled by the TRn bit. If the Counter function is
selected, the TRn and GATEn bits can be used to manage the external INTn input to count edge
transitions or measure pulse widths. The timer/counter clock source is decided by the TnPRE0 and
TnPRE1 registers in the TMPRE register. When the values in the TLn register overflows, the TLn
value will be auto-reloaded with the data in the THn register and an interrupt will take place if the
interrupt is enabled. Note that the value of THn register should be initialised by the application
program. The accompanying block diagram illustrates the 8-bit Auto-Reload Timer/Counter basic
operational blocks.
f
SYS
Tn
C/Tn=0
C/Tn=1
TRn
GATEn
INTn
P�escale�
f
SYS
/4
f
SYS
f
SYS
/6
f
SYS
/1�
/
TnPRE[1:0]
TLn Registe�
THn Registe�
A�to-�eload
Inte���pt
TFn flag
MUX
Mode 2 Block Diagram – Timer 0, 1, 3