107
CHAPTER 7 16-BIT TIMER 0 TM0
(2) Measurement of three pulse widths with free-running counter
The 16-bit timer register (TM0) allows simultaneous measurement of the pulse widths of the three signals input
to the TI00/P40 to TI02/P42 pins.
When the edge specified by bits 2 and 3 (ES00 and ES01) of prescaler mode register (PRM0) is input to the
TI00/P40 pin, the value of TM0 is taken into 16-bit capture register 00 (CR00) and an external interrupt request
signal (INTTM00) is set.
Also, when the edge specified by bits 4 and 5 (ES10 and ES11) of PRM0 is input to the TI01/P41 pin, the value
of TM0 is taken into 16-bit capture register 01 (CR01) and an external interrupt request signal (INTTM01) is set.
When the edge specified by bits 6 and 7 (ES20 and ES21) of PRM0 is input to the TI02/P42 pin, the value of
TM0 is taken into 16-bit capture register 02 (CR02) and external interrupt request signal (INTTM02) is set.
Any of three edge specifications can be selected—rising, falling, or both edges—as the valid edges for the TI00/
P40 to TI02/P42 pins by means of bits 2 and 3 (ES00 and ES01), bits 4 and 5 (ES10 and ES11), and bits 6 and
7 (ES06 and ES07) of PRM0, respectively.
For TI00/P40 pin valid edge detection, sampling is performed at the interval selected by means of the prescaler
mode register (PRM0), and a capture operation is only performed when a valid level is detected twice, thus
eliminating noise with a short pulse width.
• Capture operation
Capture register operation in capture trigger input is shown.
Figure 7-7. CR0m Capture Operation with Rising Edge Specified
Count clock
TM0
TI0m
Rising edge detection
CR0m
INTTM0m
n–3
n–2
n–1
n
n+1
n
Remark
m = 0 to 2
Содержание 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 ...