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

32-bit single-chip microcontroller
Table of Contents

Advertisement

16-Bit Timer/Event Counter AA
(3)
Figure 10-32
Note
Simultaneous pulse width and pulse space measurement
Pulse width and pulse space can be measure simultaneously in the pulse
width measurement mode, when the signal is input to both inputs TIAAn0 and
TIAAn1, where both inputs detect opposite edges.
By detection of the specified edge the resulting values of pulse width or pulse
space are captured in the corresponding capture registers (TAAnCCR0,
TAAnCCR1), and the timer is cleared and restarts counting.
Flowchart of Simultaneous Pulse Width and Pulse Space Measurement
1.
External pulse input must be input to both TIAAn0 and TIAAn1.
Specify "rising edge" for edge detection of first input, and "falling edge" for
the second input, or vice versa.
2.
x = 0, 1
y = 0 when x = 1; y = 1 when x = 0
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)
Rising edge input to TIAAnx, capture of
value to TAAnCCRx, 16-bit counter clear
& start
Falling edge input to TIAAny, capture of
value to TAAnCCRy, 16-bit counter clear
& start
Chapter 10
Note 1
361

Advertisement

Table of Contents
loading

Table of Contents