277
Chapter 10
Timer
Preliminary User’s Manual U15839EE1V0UM00
(a) Setting CCC0n registers to capture registers (set CMS1, CMS0 bits of TMCC01 to 0)
When these registers are set to capture registers, the valid edges of the corresponding external
interrupt signals TICn0 (n = 0, 1) are detected as capture triggers. The counter register TMC0 is
synchronized with the capture trigger, and the value of TMC0 is latched in the CCC00 and CCC01
registers (capture operation).
The valid edge of the TIC00 pin is specified (rising, falling, or both edges) according to the IES10
and IES00 bits of the SESC0 register.
The valid edge of the TIC01 pin is specified according to the IES11 and IES10 bits of the SESC0
register.
The capture operation is performed asynchronously relative to the count clock. The latched value
is held in the capture register until the next time the capture operation is performed.
When the CAE bit of Timer C control register 0 (TMCC00) is "0", 0000H is read.
If the CCC00 or CCC01 register is specified as capture register, an interrupt is generated
(INTCCC00 or INTCCC01) by detecting the valid edge of signals.
Caution:
If the capture operation and the TMC0 register count prohibit setting (CE bit of
TMCC00 register = 0) timings conflict, the captured data becomes undefined, and no
INTCCC00 interrupt is generated (n = 0, 1).
(b) Setting CCC0n registers to compare registers (CMS1 and CMS0 of TMCC01 = 1)
When these registers are set to compare registers, the TMC0 and register values are compared
for each timer count clock, and an interrupt is generated by a match.
If the CCLR bit of Timer C control register 1 (TMCC01) is set (1), the TMC0 value is cleared (0) at
the same time as a match with the CCC00 register (it is not cleared (0) by a match with the CCC01
register).
A compare register is equipped with a set/reset output function. The corresponding timer output
(TOC0) is set or reset, synchronized with the generation of a match signal.
The interrupt selection source differs according to the function of the selected register.
Cautions: 1. The minimum value for CCC0 to achieve a symmetrical output wave with the
"Compare Clear Enable" function (CLR bit = 1) is 0003H.
2. To write to capture/compare registers 0 and 1 (CCC00, CCC01), always set the
CAE bit to 1 first. When the CAE bit is 0, even if writing to registers CCC00 and
CCC01, the data that is written will be invalid because the reset is asynchronous.
3. Perform a write operation to capture/compare registers 0 and 1 after setting them
to compare registers according to the TMCC01 register setting. If they are set to
capture registers (CMS1 and CMS0 bits of TMCC01 register = 0), no data is written
even if a write operation is performed to CCC00 and CCC01.
4. When these registers are set to compare registers, the INTCCC00 or INTCCC01
interrupt can not be used for generating interrupts for external inputs edges.
Содержание mPD703128
Страница 6: ...6 Preliminary User s Manual U15839EE1V0UM00 ...
Страница 20: ...20 Preliminary User s Manual U15839EE1V0UM00 ...
Страница 32: ...32 Preliminary User s Manual U15839EE1V0UM00 MEMO ...
Страница 154: ...154 Preliminary User s Manual U15839EE1V0UM00 MEMO ...
Страница 238: ...238 Preliminary User s Manual U15839EE1V0UM00 MEMO ...
Страница 356: ...356 Preliminary User s Manual U15839EE1V0UM00 MEMO ...
Страница 522: ...522 Preliminary User s Manual U15839EE1V0UM00 MEMO ...
Страница 600: ...600 Preliminary User s Manual U15839EE1V0UM00 MEMO ...
Страница 610: ...610 Preliminary User s Manual U15839EE1V0UM00 ...
Страница 612: ......