A96G140/A96G148/A96A148 User’s manual
12. Timer 0/1/2/3/4/5
123
12.4.2
16-bit capture mode
Timer 3 capture mode is set by configuring T3MS[1:0] as ‘01’.
It uses an internal/external clock as a
clock source. Basically, the 16-bit timer 3 capture mode has the same function as the 16-bit
timer/counter mode, and the interrupt occurs when T3CNTH/T3CNTL is equal to T3ADRH/T3ADRL.
The T3CNTH, T3CNTL values are automatically cleared by a match signal. It can be cleared by
software (T3CC) too.
A timer interrupt in capture mode is very useful when the pulse width of captured signal is wider than
the maximum period of timer. Capture result is loaded into T3BDRH/T3BDRL.
According to EIPOL0L registers setting, the external interrupt EINT3 function is selected. EINT3 pin
must be set as an input port.
A Match
T3CC
T3EN
P
r
e
s
c
a
l
e
r
fx
M
U
X
fx/2
fx/4
fx/64
fx/512
fx/204 8
fx/8
fx/1
16-bit Cou nte r
T3CNTH/T3CNTL
16-bit B Data Re gister
T3BDRH/T3BDRL
Clear
Edg e
Detector
T3ECE
EC3
Comparator
16-bit A Data Re gister
T3ADRH/T3ADRL
T3IFR
INT_ACK
Clear
To i nte rrupt
block
A Match
Buffer Reg ister A
A Match
T3CC
Reload
R
EINT3
T3CNTR
T3EN
3
T3CK[2:0]
Clear
EIPOL0L[7:6]
FLAG3
(EIFLAG0.3)
INT_ACK
Clear
To i nte rrupt
block
2
T3MS[1:0]
2
T3EN
T3CRH
1
ADDRES S:1000H
INITIAL VALUE : 0000_0000B
–
T3MS1
T3MS0
–
–
–
T3CC
–
0
1
–
–
–
X
T3CK1
T3CRL
X
ADDRES S:1001H
INITIAL VALUE : 0000_0000B
T3CK1
T3CK0
T3IFR
–
T3POL
T3ECE T3CNTR
X
X
X
–
X
X
X
T3EN
Figure 56. 16-bit Capture Mode of Timer 3