197
CHAPTER 8 16-BIT TIMER/EVENT COUNTER
TMC0
0
0/1
1
0
0
0
0
0
OVF0
TMC01
TMC02
TMC03
Free-Running Mode
CRC0
0
0/1
1
0
0
0
0
0
CRC00
CRC01
CRC02
CR00 set as compare register
CR01 set as capture register
8.5.4 Pulse width measurement operations
It is possible to measure the pulse width of the signals input to the TI00/P00 pin and TI01/P01 pin using the
16-bit timer register (TM0).
There are two measurement methods: measuring with TM0 used in free-running mode, and measuring by
restarting the timer in synchronization with the edge of the signal input to the TI00/P00 pin.
(1) Pulse width measurement with free-running counter and one capture register
When the 16-bit timer register (TM0) is operated in free-running mode (see register settings in Figure 8-17),
and the edge specified by external interrupt mode register 0 (INTM0) is input to the TI00/P00 pin, the value
of TM0 is taken into 16-bit capture/compare register 01 (CR01) and an external interrupt request signal (INTP0)
is set.
Any of three edge specifications can be selected—rising, falling, or both edges—by means of bits 2 and 3
(ES10 and ES11) of INTM0.
For valid edge detection, sampling is performed at the interval selected by means of the sampling clock
selection register (SCS), and a capture operation is only performed when a valid level is detected twice, thus
eliminating noise with a short pulse width.
Figure 8-17. Control Register Settings for Pulse Width Measurement with
Free-Running Counter and One Capture Register
(a) 16-bit timer mode control register (TMC0)
(b) Capture/compare control register 0 (CRC0)
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.
Содержание PD78052
Страница 2: ...2 MEMO ...
Страница 8: ...8 MEMO ...
Страница 16: ...16 MEMO ...
Страница 36: ...36 MEMO ...
Страница 158: ...158 MEMO ...
Страница 174: ...174 MEMO ...
Страница 240: ...240 MEMO ...
Страница 260: ...260 MEMO ...
Страница 340: ...340 MEMO ...
Страница 392: ...392 MEMO ...
Страница 438: ...438 MEMO ...
Страница 482: ...482 CHAPTER 20 REAL TIME OUTPUT PORT MEMO ...
Страница 510: ...510 MEMO ...
Страница 524: ...524 MEMO ...
Страница 560: ...560 MEMO ...
Страница 576: ...576 MEMO ...
Страница 598: ...598 MEMO ...
Страница 602: ...602 MEMO ...