128
CHAPTER 9 8-BIT TIMER/EVENT COUNTERS 2, 3 TM2, TM3
Figure 9-7. External Event Counter Operation Timings (with Rising Edge Specified)
TIOn
TMn count value
CRn
INTTMn
0000 0001 0002 0003 0004 0005
N–1
N
0000 0001 0002 0003
N
n = 2, 3
9.4.3 Square-wave output operation (8-bit resolution)
A square wave with any selected frequency is output at intervals of the value preset to 8-bit compare register n
(CRn).
TIOn pin output status is inverted at intervals of the count value preset to CRn by setting bit 0 (TOEn) of 8-bit timer
mode control register n (TMCn) to 1. This enables a square wave with any selected frequency to be output (duty
= 50%).
[Setting]
<1> Set each register.
• Set port latch and port mode register to 0.
• TCLn: Select count clock
• CRn: compare value
• TMCn: Clear and start mode by match of TMn and CRn
LVSn
LVRn
Timer Output F/F Status Setting
1
0
High-level output
0
1
Low-level output
Timer output F/F inversion enabled
Timer output enabled
→
TOEn = 1
<2> After TCEn = 1 is set, count operation starts.
<3> Timer output F/F is inverted by match of TMn and CRn. After INTTMn is generated, TMn is cleared to 00H.
<4> Timer output F/F is inverted at the same interval and square wave is output from TIOn.
Remark 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 ...