English
Language : 

7702 Datasheet, PDF (160/522 Pages) Renesas Technology Corp – 16-BIT SINGLE-CHIP MICROCOMPUTER
TIMER B
6.5 Pulse period/pulse width measurement mode
6.5.3 Operation in pulse period/pulse width measurement mode
Œ When the count start bit is set to “1,” the counter starts counting of the count source.
 The counter value is transferred to the reload register when an valid edge of the measurement pulse
is detected. (Refer to section “(1) Pulse period/pulse width measurement.”)
Ž The counter value is cleared to “000016” after the transfer in , and the counter continues counting.
 The timer Bi interrupt request bit is set to “1” when the counter value is cleared to “000016” in Ž (Note).
The interrupt request bit remains set to “1” until the interrupt request is accepted or the interrupt request
bit is cleared to “0” by software.
 The timer repeats operations  to  above.
Note: The timer Bi interrupt request does not occur when the first valid edge is input after the timer starts
counting.
(1) Pulse period/pulse width measurement
The measurement mode select bits (bits 2 and 3 at addresses 5B16 to 5D16) specify whether the pulse
period of an external signal is measured or its pulse width is done. Table 6.5.3 lists the relationship
between the measurement mode select bits and the pulse period/pulse width measurements.
Make sure that the measurement pulse interval from the falling to the rising, and from the rising to
the falling are two cycles of the count source or more. Additionally, use software to identify whether
the measurement result indicates the “H” level or the “L” level width.
Table 6.5.3 Relationship between measurement mode select bits and pulse period/pulse width measurements
b3 b2 Pulse period/pulse width measurement Measurement interval (Valid edges)
0 0 Pulse period measurement
From falling to falling (Falling)
01
From rising to rising (Rising)
1 0 Pulse width measurement
1 1 Not selected
From falling to rising, and from rising to falling
(Falling and rising)
6–24
7702/7703 Group User’s Manual