Datasheet
V850ES/JG3-H, V850ES/JH3-H CHAPTER 8 16-BIT TIMER/EVENT COUNTER AB (TAB)
R01UH0042EJ0500 Rev.5.00 Page 347 of 1513
Aug 12, 2011
(a) Function as compare register
The TABnCCR2 register can be rewritten even when the TABnCTL0.TABnCE bit = 1.
The set value of the TABnCCR2 register is transferred to the CCR2 buffer register. When the value of the 16-
bit counter matches the value of the CCR2 buffer register, a compare match interrupt request signal
(INTTABnCC2) is generated. If TOABn2 pin output is enabled at this time, the output of the TOABn2 pin is
inverted.
(b) Function as capture register
When the TABnCCR2 register is used as a capture register in the free-running timer mode, the count value of
the 16-bit counter is stored in the TABnCCR2 register if the valid edge of the capture trigger input pin (TIABn2
pin) is detected. In the pulse width measurement mode, the count value of the 16-bit counter is stored in the
TABnCCR2 register and the 16-bit counter is cleared (0000H) if the valid edge of the capture trigger input pin
(TIABn2 pin) is detected.
Even if the capture operation and reading the TABnCCR2 register conflict, the correct value of the TABnCCR2
register can be read.
Remark n = 0, 1
The following table shows the functions of the capture/compare register in each mode, and how to write data to the
compare register.
Table 8-4. Function of Capture/Compare Register in Each Mode and How to Write Compare Register
Operation Mode Capture/Compare Register How to Write Compare Register
Interval timer Compare register Anytime write
External event counter Compare register Anytime write
External trigger pulse output Compare register Batch write
One-shot pulse output Compare register Anytime write
PWM output Compare register Batch write
Free-running timer Capture/compare register Anytime write
Pulse width measurement Capture register
−
Triangular wave PWM mode Compare register Batch write