
R8C/36T-A Group
15. Timer RJ
Under development Preliminary document
Specifications in this document are tentative and subject to change.
R01UH0240EJ0010 Rev.0.10
Page 236 of 728
Aug 05, 2011
15.4.4
Event Counter Mode
In this mode, the counter is decremented by an external event signal (count source) input to the TRJIO pin.
Various periods for counting events can be set by bits TIOGT0 and TIOGT1 in the TRJIOC register and the
TRJISR register. In addition, the filter function for the TRJIO input can be specified by bits TIPF0 and TIPF1 in
the TRJIOC register.
Also, the output from the TRJO pin can be toggled even in event counter mode.
Figure 15.5
Operation Timing Example in Event Counter Mode
Bits TMOD2 to TMOD0
in TRJMR register
The event is counted at the rising edge
010b
Event counter mode is entered
Event input starts
Event input ends
00h
TRJIOC register
TSTART bit in
TRJCR register
TRJIO pin
event input
Timer RJ counter
The counter initial value is set
FFFEh
FFFFh
FFFDh
0000h
FFFFh
FFFEh