NEC V850E/MA1 User Manual page 355

32-bit single-chip microcontroller
Hide thumbs Also See for V850E/MA1:
Table of Contents

Advertisement

CHAPTER 10 TIMER/COUNTER FUNCTION (REAL-TIME PULSE UNIT)
10.2.6 Timer D operation
(1) Compare operation
TMDn can be used for a compare operation in which the value that was set in a compare register (CMDn) is
compared with the TMDn count value (n = 0 to 3).
If a match is detected by the compare operation, an interrupt (INTCMDn) is generated. The generation of the
interrupt causes TMDn to be cleared (0) at the next count timing. This function enables timer D to be used as
an interval timer.
CMDn can also be set to 0. In this case, when an overflow occurs and TMDn becomes 0, a match is
detected and INTCMDn is generated. Although the TMDn value is cleared (0) at the next count timing,
INTCMDn is not generated by this match.
Count clock
Count up
TMD0 clear
TMD0
CMD0
Match detected
(INTCMD0)
Interval time = (n + 1) × (Count clock cycle)
Remark
n = 1 to 65,536 (FFFFH)
Figure 10-14. TMD0 Compare Operation Example (1/2)
(a) When CMD0 is set to n (non-zero)
n
User's Manual U14359EJ4V0UM
Clear
0
n
1
355

Advertisement

Table of Contents
loading

Table of Contents