CHAPTER 6 16-BIT TIMER/EVENT COUNTER 00
User’s Manual U18172EJ2V0UD
98
Figure 6-19. Control Register Settings for Pulse Width Measurement with Free-Running Counter
and One Capture Register (When TI000 and CR010 Are Used)
(a) Capture/compare control register 00 (CRC00)
7
0
6
0
5
0
4
0
3
0
CRC002
1
CRC001
0/1
CRC000
0
CRC00
CR000 used as compare register
CR010 used as capture register
(b) Prescaler mode register 00 (PRM00)
ES101
0/1
ES100
0/1
ES010
1
ES000
1
3
0
2
0
PRM001
0/1
PRM000
0/1
PRM00
Selects count clock (setting “11” is prohibited).
Specifies both edges for pulse width detection.
Setting invalid (setting “10” is prohibited.)
(c) 16-bit timer mode control register 00 (TMC00)
7
0
6
0
5
0
4
0
TMC003
0
TMC002
1
TMC001
0/1
OVF00
0
TMC00
Free-running mode
Remark
0/1: Setting 0 or 1 allows another function to be used simultaneously with pulse width measurement.
See the description of the respective control registers for details.
Figure 6-20. Configuration Diagram for Pulse Width Measurement by Free-Running Counter
f
XP
f
XP
/2
2
f
XP
/2
8
16-bit timer/counter 00
(TM00)
16-bit timer capture/compare
register 010 (CR010)
Internal bus
INTTM010
Selector
TI000/ANI0/
TOH1/P20