NEC 78K0 Series User Manual page 238

8-bit single-chip microcontrollers
Hide thumbs Also See for 78K0 Series:
Table of Contents

Advertisement

Figure 7-57. Example of Software Processing for Pulse Width Measurement (2/2)
<1> Count operation start flow
<2> Capture trigger input flow
Edge detection of TI00n, TI01n pins
Generates capture interrupt
<3> Count operation stop flow
TMC0n3, TMC0n2 bits = 00
Note The capture interrupt signal (INTTM00n) is not generated when the reverse-phase edge of the TI00n pin
input is selected to the valid edge of CR00n.
µ
Remark n = 0:
PD78F0531, 78F0532, 78F0533
µ
n = 0, 1:
PD78F0534, 78F0535, 78F0536, 78F0537, 78F0537D
238
CHAPTER 7 16-BIT TIMER/EVENT COUNTERS 00 AND 01
START
Register initial setting
PRM0n register,
CRC0n register,
port setting
TMC0n3, TMC0n2 bits =
01 or 10
Stores count value to
CR00n, CR01n registers
Note
Calculated pulse width
from capture value
STOP
Preliminary User's Manual U17260EJ3V1UD
Initial setting of these registers is performed
before setting the TMC0n3 and TMC0n2 bits.
Starts count operation
The counter is initialized and counting is stopped
by clearing the TMC0n3 and TMC0n2 bits to 00.

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents