![](http://datasheet.mmic.net.cn/30000/M30260M3A-XXXGP-U5_datasheet_2358673/M30260M3A-XXXGP-U5_105.png)
12. Timer
page 91
8
2
3
f
o
5
0
2
,
5
1
.
r
a
M
0
.
1
.
v
e
R
0
1
0
-
2
0
2
0
B
9
0
J
E
R
)
T
6
2
/
C
6
1
M
,
A
6
2
/
C
6
1
M
(
p
u
o
r
G
A
6
2
/
C
6
1
M
Symbol
Address
After reset
CPSRF
038116
0XXXXXXX2
Clock prescaler reset flag
Bit name
Function
Bit symbol
b7
b6
b5
b4
b3
b2
b1
b0
Clock prescaler reset flag
Setting this bit to “1” initializes the
prescaler for the timekeeping clock.
(When read, its content is “0”.)
CPSR
Nothing is assigned.
When write, set to “0”. When read, their contents are
indeterminate.
TA1TGL
Symbol
Address
After reset
TRGSR
038316
0016
Timer A1 event/trigger
select bit
0 0 : Input on TA1IN is selected (Note 1)
0 1 : TB2 overflow is selected
1 0 : TA0 overflow is selected
1 1 : TA2 overflow is selected
Trigger select register
Bit name
Function
Bit symbol
b7
b6
b5
b4
b3
b2
b1
b0
0 0 : Input on TA2IN is selected (Note 1)
0 1 : TB2 overflow is selected
1 0 : TA1 overflow is selected
1 1 : TA3 overflow is selected
0 0 : Input on TA3IN is selected (Note 1)
0 1 : TB2 overflow is selected
1 0 : TA2 overflow is selected
1 1 : TA4 overflow is selected
0 0 : Input on TA4IN is selected (Note 1)
0 1 : TB2 overflow is selected
1 0 : TA3 overflow is selected
1 1 : TA0 overflow is selected
Timer A2 event/trigger
select bit
Timer A3 event/trigger
select bit
Timer A4 event/trigger
select bit
TA1TGH
TA2TGL
TA2TGH
TA3TGL
TA3TGH
TA4TGL
TA4TGH
b1 b0
b3 b2
b5 b4
b7 b6
Note 1: Make sure the port direction bits for the TA1 IN to TA4IN pins are set to “0” (= input mode).
Note 2: Overflow or underflow
TA1OS
TA2OS
TA0OS
One-shot start flag
Symbol
Address
After reset
ONSF
038216
0016
Timer A0 one-shot start flag
Timer A1 one-shot start flag
Timer A2 one-shot start flag
Timer A3 one-shot start flag
Timer A4 one-shot start flag
TA3OS
TA4OS
Bit name
Function
Bit symbol
b7
b6
b5
b4
b3
b2
b1
b0
TA0TGL
TA0TGH
0 0 : Input on TA0 IN is selected
0 1 : TB2 overflow is selected
1 0 : TA4 overflow is selected
1 1 : TA1 overflow is selected
Timer A0 event/trigger
select bit
b7 b6
RW
The timer starts counting by setting
this bit to “1” while the TMOD1 to
TMOD0 bits
TAiMR register
(i = 0 to 4)
‘102’ (= one-
shot timer mode) and the MR2 bit
TAiMR register
“0”
(=TAiOS bit enabled). When read,
its content is “0”.
Z-phase input enable bit
TAZIE
0 : Z-phase input disabled
1 : Z-phase input enabled
RW
(b6-b0)
(Note 2)
Note 1: Make sure the PD7_1 bit in the PD7 register is set to “0” (= input mode).
Note 2: Overflow or underflow
(Note 1)
(Note 2)
Figure 12.1.4. ONSF Register, TRGSR Register, and CPSRF Register