Timer Mode - Renesas M16C/6NK Hardware Manual

16-bit single-chip microcomputer m16c family / m16c/60 series
Table of Contents

Advertisement

Under development
This document is under development and its contents are subject to change.
M16C/6N Group (M16C/6NK, M16C/6NM)

13.2.1 Timer Mode

In timer mode, the timer counts a count source generated internally.
Table 13.6 lists specifications in timer mode. Figure 13.18 shows TBiMR register in timer mode.
Table 13.6 Specifications in Timer Mode
Item
Count Source
Count Operation
Divide Ratio
Count Start Condition
Count Stop Condition
Interrupt Request Generation Timing Timer underflow
TBiIN Pin Function
Read from Timer
Write to Timer
i = 0 to 5
NOTE:
1. The TB0S to TB2S bits are assigned to the bit 5 to bit 7 in the TABSR register, and the TB3S to TB5S
bits are assigned to the bit 5 to bit 7 in the TBSR register.
Timer Bi Mode Register (i = 0 to 5)
b7
b6
b5
b4
b3
b2
Figure 13.18 TB0MR to TB5MR Registers in Timer Mode
Rev.2.00
Nov 28, 2005
REJ09B0124-0200
f1, f2, f8, f32, fC32
• Down-count
• When the timer underflows, it reloads the reload register contents and
continues counting
1/(n+1) n: set value of the TBi register
(1)
Set the TBiS bit
Set the TBiS bit to "0" (stop counting)
I/O port
Count value can be read by reading the TBi register
• When not counting and until the 1st count source is input after counting start
Value written to the TBi register is written to both reload register and counter
• When counting (after 1st count source input)
Value written to the TBi register is written to only reload register
(Transferred to counter when reloaded next)
b1
b0
Symbol
0
0
TB0MR to TB2MR
TB3MR to TB5MR
Bit Symbol
TMOD0
Operation Mode Select Bit 0 0 : Timer mode
TMOD1
MR0
Has no effect in timer mode
Can be set to "0" or "1"
MR1
TB0MR, TB3MR registers
Set to "0" in timer mode
MR2
TB1MR, TB2MR, TB4MR, TB5MR register s
Nothing is assigned. When write, set to "0".
When read, its content is indeterminate.
When write in timer mode, set to "0".
MR3
When read in timer mode, its content is indeterminate.
TCK0
Count Source Select Bit
TCK1
page 133 of 378
Specification
to "1" (start counting)
Address
After Reset
039Bh to 039Dh
00XX0000b
00XX0000b
01DBh to 01DDh
Bit Name
b1 b0
b7 b6
0 0 : f1 or f2
0 1 : f8
1 0 : f32
1 1 : fC32
0000h to FFFFh
Function
RW
RW
RW
RW
RW
RW
RO
RW
RW
13. Timers
-

Advertisement

Table of Contents
loading

This manual is also suitable for:

M16c/6nm

Table of Contents