Renesas M16C/62P Series Hardware Manual page 155

6-bit single-chip microcomputer
Table of Contents

Advertisement

M16C/62P Group (M16C/62P, M16C/62PT)
Timer Ai Mode Register (i=0 to 4)
b7 b6 b5 b4
b3 b2 b1 b0
Timer Ai Register (i= 0 to 4)
(b15)
(b8)
b7
b0
b7
Timer Mode
Event Counter
Mode
One-Shot Timer
Mode
Pulse Width
Modulation Mode
(16-Bit PWM)
Pulse Width
Modulation Mode
(8-Bit PWM)
NOTES :
1.
The register must be accessed in 16-bit units.
2.
If the TAi register is set to "0000h", the counter does not w ork and timer Ai interrupt requests are not generated
either. Furthermore, if "pulse output" is selected, no pulses are output from the TAiOUT pin.
3.
If the TAi register is set to "0000h", the pulse w idth modulator does not w ork, the output level on the TAiOUT pin
remains low , and timer Ai interrupt requests are not generated either. The same applies w hen the 8 high-order bits
of the timer TAi register are set to "00h" w hile operating as an 8-bit pulse w idth modulator.
4.
Use the MOV instruction to w rite to the TAi register.
5.
The timer counts pulses from an external device or overflow s or underflow s in other timers.
Figure 15.4
TAiMR and TAi Registers
Rev.2.41
Jan 10, 2006
REJ09B0185-0241
http://www.xinpian.net
Symbol
0396h to 039Ah
TA0MR to TA4MR
Bit Name
Bit Symbol
Operation Mode Select Bit
TMOD0
TMOD1
MR0
MR1
MR2
MR3
TCK0
Count Source Select Bit
TCK1
(1)
Symbol
TA0
b0
TA1
TA2
TA3
TA4
Mode
Divide the count source by n + 1 w here n = set
value
Divide the count source by FFFFh – n + 1 w here
n = set value w hen counting up or by n + 1 w hen
counting dow n
Divide the count source by n w here n = set value
and factor the timer to stop
Modify the pulse w idth as follow s:
PWM period: (2
High level PWM pulse w idth: n / fj
w here n = set value, fj = count source frequency
Modify the pulse w idth as follow s:
PWM period: (2
High level PWM pulse w idth: (m + 1)n / fj
w here n = high-order address set value,
m = low -order address set value, fj = count
source frequency
Page 140 of 390
提供单片机解密、IC解密、芯片解密业务
Address
b1 b0
0 0 : Timer mode
0 1 : Event counter mode
1 0 : One-shot timer mode
1 1 : Pulse w idth modulation (PWM) mode
Function varies w ith each operation mode
Function varies w ith each operation mode
Address
0387h, 0386h
0389h, 0388h
038Bh, 038Ah
038Dh, 038Ch
038Fh, 038Eh
Function
(5)
16
– 1) / fj
8
– 1) × (m + 1)/ fj
After Reset
00h
Function
After Reset
Indeterminate
Indeterminate
Indeterminate
Indeterminate
Indeterminate
Setting Range
0000h to FFFFh
0000h to FFFFh
(2, 4)
0000h to FFFFh
0000h to FFFEh
(3, 4)
00h to FEh
(High-order address)
00h to FFh
(Low -order address)
(3, 4)
010-62245566 13810019655
15. Timers
RW
RW
RW
RW
RW
RW
RW
RW
RW
RW
RW
RW
WO
WO
WO

Advertisement

Table of Contents
loading

This manual is also suitable for:

M16c/62pM16c/62pt

Table of Contents