NEC V850ES/F 3-L Series User Manual page 357

32-bit single-chip microcontroller
Table of Contents

Advertisement

16-Bit Timer/Event Counter AA
(1)
Figure 10-28
Note
Pulse period measurement
The pulse period of a signal can be measured in the pulse width measurement
mode, when the edge detection of one of the inputs TIAAn0 and TIAAn1 is set
either to "rising edge" or "falling edge". The detection of the other input should
be set to "no edge detection".
By detection of the specified edge the resulting value is captured in the
corresponding capture register (TAAnCCR0 or TAAnCCR1), and the timer is
cleared and restarts counting.
Flowchart of Pulse Period Measurement
1.
External pulse input is possible for both TIAAn0 and TIAAn1, but only one
should be selected for the pulse period measurement.
Specify either "rising edge" or "falling edge" for edge detection. Specify the
edge of the external input pulse that is not used as "no edge detection".
2.
m = 0, 1
User's Manual U18743EE1V2UM00
START
Initial settings
• Clock selection
(TAAnCTL0: TAAnCKS2 to TAAnCKS0)
• Pulse width measurement mode setting
(TAAnCTL1: TAAnMD2 to TAAnMD0 =
110B)
• Capture register setting
(TAAnCCR0, TAAnCCR1)
TIAAn1/TIAAn0 edge detection setting
(TAAnIS3 to TAAnIS0)
Timer operation enable (TAAnCE = 1)
Specified edge input to TIAAnm (rising or
falling edge), capture of value to
TAAnCCRm, 16-bit counter clear & start
Chapter 10
Note 1
357

Advertisement

Table of Contents
loading

Table of Contents