Download Print this page

Renesas M16C/50 Series User Manual page 413

Advertisement

M16C/5L Group, M16C/56 Group
18.3.2
Time Measurement Function
The base timer value is stored in the G1TMj register (j = 0 to 7) using an external input as a trigger. Table
18.10 lists the specifications of the time measurement function. Table 18.11 lists the time measurement
function associated registers and their settings. Figure 18.11 to Figure 18.12 show the operation
examples of the time measurement function.
Figure 18.13 shows the operation example of the prescaler function and gate function.
Table 18.10
Time Measurement Function Specifications
Item
Measurement channels
Trigger input polarity
Measurement start condition
Measurement stop condition Set the IFEj bit to 0 (channel j function disabled).
Time measurement timing
Interrupt request occurrence
timing
INPC1_ j pin function
Selectable functions
j = 0 to 7; k = 6 and 7
R01UH0127EJ0110 Rev.1.10
Sep 01, 2011
Channels 0 to 7
Selectable from rising edge, falling edge, or both edges of the INPC1_j pin input.
While the FSCj bit in the G1FS register is 1 (time measurement function selected), set
the IFEj bit in the G1FE register to 1 (channel j function enabled).
Without prescaler: every trigger input
With prescaler (channels 6 and 7): every (G1TPRk register value + 1) time a trigger is
input
At the time measurement timing
Trigger input
Digital filter
The digital filter judges a trigger input level at each sampling clock (f1TIMS, f2TIMS,
or fBT1) and passes the pulse that matches its signal level three times.
Prescaler (channels 6 and 7)
Time measurement is executed every (G1TPRk register value + 1) times a trigger is
input.
Gate function (channels 6 and 7)
After a time measurement is performed by the first trigger input, subsequent trigger
inputs are disabled.
Digital debounce filter (channel 7)
When P1_7/INPC1_7 is selected, the digital debounce filter is enabled.
Specification
18. Timer S
Page 376 of 803

Advertisement

loading