125
CHAPTER 9 8-BIT TIMER/EVENT COUNTERS 2, 3 TM2, TM3
9.4 8-Bit Timer/Event Counters 2 and 3 Operations
9.4.1 8-bit interval timer operation
The 8-bit timer/event counters operate as interval timers which generate interrupt requests repeatedly at intervals
of the count value preset to 8-bit compare register n (CRn).
When the count values of the 8-bit counter n (TMn) match the values set to CRn, counting continues with the TMn
values cleared to 0 and the interrupt request signal (INTTMn) is generated.
Count clock of the TMn can be selected with bits 0 to 2 (TCLn0 to TCLn2) of the timer clock select register n (TCLn).
[Setting]
<1> Set the registers.
• TCLn : Select count clock.
• CRn
: Compare value
• TMCn : Select clear and start mode by match of TMn and CRn.
(TMCn = 0000
×××
0B
×
= don’t care)
<2> After TCEn = 1 is set, count operation starts.
<3> If the values of TMn and CRn match, the INTTMn is generated and TMn is cleared to 00H.
<4> INTTMn generates repeatedly at the same interval. Set TCEn to 0 to stop count operation.
Remark n = 2, 3
Figure 9-6. Interval Timer Operation Timings (1/3)
(a) Basic operation
t
Count clock
TMn count value
CRn
TCEn
INTTMn
TIOn
Start count
Clear
Clear
00H
01H
N
00H
01H
N
00H
01H
N
N
N
N
N
Interrupt received
Interrupt received
Interval time
Interval time
Interval time
Remarks 1. Interval time = (N + 1)
×
t: N = 00H to FFH
2. n = 2, 3
Содержание mPD780973 Series
Страница 2: ...2 MEMO ...
Страница 66: ...66 MEMO ...
Страница 98: ...98 MEMO ...
Страница 138: ...138 MEMO ...
Страница 164: ...164 MEMO ...
Страница 182: ...182 MEMO ...
Страница 204: ...204 MEMO ...
Страница 244: ...244 MEMO ...
Страница 262: ...262 MEMO ...
Страница 278: ...278 MEMO ...
Страница 290: ...290 MEMO ...