Renesas M16C/6NK Hardware Manual page 134

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)
Timer Ai Mode Register (i = 0 to 4)
b7
b6
b5
b4
b3
b2
Timer Ai Register (i = 0 to 4)
(b15)
b7
NOTES:
1.The register must be accessed in 16-bit unit.
2.The timer counts pulses from an external device or overflows or underflows in other timers.
3.If the TAi register is set to "0000h", the counter does not work and timer Ai interrupt requests are
not generated either. Furthermore, if "pulse output" is selected, no pulses are output from the
TAiOUT pin.
4.Use the MOV instruction to write to the TAi register.
5.If the TAi register is set to "0000h", the pulse width modulator does not work, the output level on
the TAiOUT pin remains low, and timer Ai interrupt requests are not generated either.
The same applies when the 8 high-order bits in the TAi register are set to "00h" while operating as
an 8-bit pulse width modulator.
Figure 13.4 TA0MR to TA4MR Registers and TA0 to TA4 Registers
Rev.2.00
Nov 28, 2005
REJ09B0124-0200
b1
b0
Symbol
TA0MR to TA4MR
Bit Symbol
TMOD0
Operation Mode Select Bit
TMOD1
MR0
MR1
Function varies with each operation mode
MR2
MR3
TCK0
Count Source Select Bit
TCK1
(1)
(b8)
b0 b7
b0
Mode
Timer
Divide the count source by n + 1 where n =
Mode
set value
Event
Divide the count source by FFFFh — n + 1
Counter
where n = set value when counting up or
Mode
by n + 1 when counting down
One-shot
Divide the count source by n where n = set
Timer Mode
value and cause the timer to stop
Modify the pulse width as follows:
Pulse Width
PWM period: (2
Modulation
High level PWM pulse width: n / fj
Mode
where n = set value, fj = count source
(16-bit PWM )
frequency
Pulse Width
Modify the pulse width as follows:
Modulation
PWM period: ( 2
Mode
High level PWM pulse width: (m + 1)n / fj
(8-bit PWM )
where n = high-order address set value,
m = low-order address set value, fj =
count source frequency
page 116 of 378
Address
After Reset
0396h to 039Ah
Bit Name
b1 b0
0 0 : Timer mode
0 1 : Event counter mode
1 0 : One-shot timer mode
1 1 : Pulse width modulation mode
Function varies with each
operation mode
Symbol
Address
TA0
0387h to 0386h
TA1
0389h to 0388h
TA2
038Bh to 038Ah
TA3
038Dh to 038Ch
TA4
038Fh to 038Eh
Function
(2)
16
— 1) / fj
— 1) ✕ (m + 1)/ fj
8
00h
Function
After Reset
Indeterminate
Indeterminate
Indeterminate
Indeterminate
Indeterminate
Setting Range
RW
0000h to FFFFh
RW
RW
0000h to FFFFh
(3) (4)
WO
0000h to FFFFh
(4) (5)
WO
0000h to FFFEh
00h to FEh
(High-order address)
WO
00h to FFh
(Low-order address)
13. Timers
RW
RW
RW
RW
RW
RW
RW
RW
RW

Advertisement

Table of Contents
loading

This manual is also suitable for:

M16c/6nm

Table of Contents