M30622SAFP MITSUBISHI [Mitsubishi Electric Semiconductor], M30622SAFP Datasheet - Page 82

no-image

M30622SAFP

Manufacturer Part Number
M30622SAFP
Description
SINGLE-CHIP 16-BIT CMOS MICROCOMPUTER
Manufacturer
MITSUBISHI [Mitsubishi Electric Semiconductor]
Datasheet

Available stocks

Company
Part Number
Manufacturer
Quantity
Price
Part Number:
M30622SAFP
Manufacturer:
AVAGO
Quantity:
18
Part Number:
M30622SAFP
Manufacturer:
MITSUBISHI
Quantity:
852
Part Number:
M30622SAFP
Manufacturer:
MITSUBISHI
Quantity:
20 000
Part Number:
M30622SAFP#U5
Manufacturer:
Renesas Electronics America
Quantity:
10 000
Timer A
82
Table 1.14.2. Timer specifications in event counter mode (when not processing two-phase pulse signal)
Note: This does not apply when the free-run function is selected.
Figure 1.14.8. Timer Ai mode register in event counter mode
(2) Event counter mode
Count source
Count operation
Divide ratio
Count start condition
Count stop condition
Interrupt request generation timing The timer overflows or underflows
TAi
TAi
Read from timer
Write to timer
Select function
In this mode, the timer counts an external signal or an internal timer’s overflow. Timers A0 and A1 can
count a single-phase external signal. Timers A2, A3, and A4 can count a single-phase and a two-phase
external signal. Table 1.14.2 lists timer specifications when counting a single-phase external signal.
Figure 1.14.8 shows the timer Ai mode register in event counter mode.
Table 1.14.3 lists timer specifications when counting a two-phase external signal. Figure 1.14.9 shows
the timer Ai mode register in event counter mode.
IN
OUT
pin function
pin function
Item
Timer Ai mode register
b7
b6
b5
0
b4
b3
b2
• External signals input to TAi
• TB2 overflow, TAj overflow
• Up count or down count can be selected by external signal or software
• When the timer overflows or underflows, it reloads the reload register con
1/ (FFFF
1/ (n + 1) for down count
Count start flag is set (= 1)
Count start flag is reset (= 0)
Programmable I/O port or count source input
Programmable I/O port, pulse output, or up/down count select input
Count value can be read out by reading timer Ai register
• When counting stopped
• When counting in progress
• Free-run count function
• Pulse output function
b1
0 1
tents before continuing counting (Note)
When a value is written to timer Ai register, it is written to both reload register and counter
When a value is written to timer Ai register, it is written to only reload register
(Transferred to counter at next reload time)
Even when the timer overflows or underflows, the reload register content is not reloaded to it
Each time the timer overflows or underflows, the TAi
b0
Note 1: In event counter mode, the count source is selected by the event / trigger select bit
Note 2: The settings of the corresponding port register and port direction register are invalid.
Note 3: Valid only when counting an external signal.
Note 4: When an “L” signal is input to the TAi
Bit symbol
TMOD0
TMOD1
MR1
TCK0
TCK1
MR0
MR2
MR3
(addresses 0382
the upcount is activated. Set the corresponding port direction register to “0”.
16
Symbol
TAiMR(i = 0, 1)
- n + 1) for up count
Operation mode select bit
Pulse output function
select bit
Up/down switching
cause select bit
0 (Must always be fixed to “0” in event counter mode)
Count polarity
select bit (Note 3)
Count operation type
select bit
Invalid in event counter mode
Can be “0” or “1”
Bit name
16
and 0383
0396
Address
16
, 0397
16
).
IN
0 : Pulse is not output
1 : Pulse is output (Note 2)
Specification
16
b1 b0
0 1 : Event counter mode (Note 1)
0 : Counts external signal's falling edge
1 : Counts external signal's rising edge
0 : Up/down flag's content
1 : TA
0 : Reload type
1 : Free-run type
pin (effective edge can be selected by software)
(TA
(TA
When reset
OUT
iOUT
iOUT
iOUT
00
pin, the downcount is activated. When “H”,
pin's input signal (Note 4)
pin is a normal port pin)
pin is a pulse output pin)
n : Set value
16
Function
SINGLE-CHIP 16-BIT CMOS MICROCOMPUTER
OUT
R
R W
pin’s polarity is reversed
W
M16C / 62A Group
Mitsubishi microcomputers

Related parts for M30622SAFP