Operation Of Timer A (Event Counter Mode, Reload Type Selected) - Renesas M30245 Series User Manual

16-bit single-chip microcomputer
Hide thumbs Also See for M30245 Series:
Table of Contents

Advertisement

M30245 Group

2.2.5 Operation of Timer A (event counter mode, reload type selected)

In event counter mode, choose functions from those listed in Table 2.2.4. Operations of the circled items
are described below. Figure 2.2.12 shows the operation timing, and Figure 2.2.13 shows the set-up
procedure.
Table 2.2.4. Choosed functions
Item
Count source
Note: j = i – 1, but j = 4 when i = 0.
(1) Setting the count start flag to "1" causes the counter to count the falling edges of the count
Operation
source.
(2) If an underflow occurs, the content of the reload register is reloaded, and the count continues.
At this time, the timer Ai interrupt request bit goes to "1".
(3) If switching from an up count to a down count or vice versa while a count is in progress, the
switch takes effect from the next effective edge of the count source.
(4) Setting the count start flag to "0" causes the counter to hold its value and to stop.
(5) If an overflow occurs, the content of the reload register is reloaded, and the count continues.
At this time, the timer Ai interrupt request bit goes to "1".
FFFF
16
n
0000
16
"1"
Count start flag
"0"
"1"
Up/down flag
"0"
Timer Ai interrupt
"1"
request bit
"0"
Figure 2.2.12. Operation timing of event counter mode, reload type selected
Rev.2.00 Oct 16, 2006
REJ09B0340-0200
Set-up
Input signal to TAi
O
(counting falling edges)
Input signal to TAi
(counting rising edges)
TAj overflow
n = reload register content
(1) Start count
(2) Underflow
Set to "1" by software
Set to "1" by software
Cleared to "0" when interrupt request is accepted, or cleared by software
page 18 of 354
Item
Pulse output function
IN
Count operation type
IN
Factor for switching
between up and
down
(3) Switch count
(4) Stop count
Cleared to "0" by
software
2. Timer A
Set-up
O
No pulses output
Pulses output
O
Reload type
Free-run type
O
Content of up/down flag
Input signal to TAi
OUT
(5) Overflow
Start count again
Time
Set to "1" by software

Advertisement

Table of Contents
loading

This manual is also suitable for:

M16c seriesM20c series

Table of Contents