9. Timers
Rev.3.00 Jul. 19, 2007 page 224 of 532
REJ09B0397-0300
Timer Load Register C (TLC)
Bit
7 6 5 4 3 2 1 0
TLC7 TLC6 TLC5 TLC4 TLC3 TLC2 TLC1 TLC0
Initial
value 0 0 0 0 0 0 0 0
Read/Write W W W W W W W W
TLC is an 8-bit write-only register for setting the reload value of TCC.
When a reload value is set in TLC, the same value is loaded into timer counter C (TCC) as well,
and TCC starts counting up or down from that value. When TCC overflows or underflows during
operation in auto-reload mode, the TLC value is loaded into TCC. Accordingly, overflow and
underflow periods can be set within the range of 1 to 256 input clocks.
The same address is allocated to TLC as to TCC.
Upon reset, TLC is initialized to H'00.
9.4.3 Timer
Operation
Interval Timer Operation:
When bit TMC7 in timer mode register C (TMC) is cleared to 0,
timer C functions as an 8-bit interval timer.
Upon reset, timer counter C (TCC) is initialized to H'00 and TMC to H'18. After a reset, the
counter continues uninterrupted incrementing as an interval up-counter. The clock input to timer C
is selected from seven internal clock signals output by prescalers S and W, or an external clock
input at pin TMIC. The selection is made by bits TMC2 to TMC0 in TMC.
Either software or hardware can control whether TCC counts up or down. The selection is made
by TMC bits TMC6 and TMC5.
After the count value in TCC reaches H'FF (H'00), the next clock signal input causes timer C to
overflow (underflow), setting bit IRRTC to 1 in interrupt request register 2 (IRR2). If IENTC = 1
in interrupt enable register 2 (IENR2), a CPU interrupt is requested.*
At overflow or underflow, TCC returns to H'00 or H'FF and starts counting up or down again.
During interval timer operation (TMC7 = 0), when a value is set in timer load register C (TLC),
the same value is set in TCC.
Note: * For details on interrupts, see section 3.3, Interrupts.
Summary of Contents for F-ZTAT H8 Series
Page 6: ...Rev 3 00 Jul 19 2007 page iv of xxiv REJ09B0397 0300...
Page 194: ...7 RAM Rev 3 00 Jul 19 2007 page 168 of 532 REJ09B0397 0300...
Page 234: ...8 I O Ports Rev 3 00 Jul 19 2007 page 208 of 532 REJ09B0397 0300...
Page 274: ...9 Timers Rev 3 00 Jul 19 2007 page 248 of 532 REJ09B0397 0300...
Page 352: ...12 A D Converter Rev 3 00 Jul 19 2007 page 326 of 532 REJ09B0397 0300...
Page 561: ......