English
Language : 

M30222 Datasheet, PDF (90/237 Pages) Mitsubishi Electric Semiconductor – SINGLE-CHIP 16-BIT CMOS MICROCOMPUTER
deUvnedloepr ment
Specifications in this manual are tentative and subject to change
MITSUBISHI MICROCOMPUTERS
M30222 Group
Rev. G
Timer B
SINGLE-CHIP 16-BIT CMOS MICROCOMPUTER
Timer Bi mode register
b7 b6 b5 b4 b3 b2 b1 b0
10
Symbol
Address
TBiMR(i=0 to 5) 039B16 to 039D16
035B16 to 035D16
When reset
00XX00002
00XX00002
Bit symbol
Bit name
TMOD0
TMOD1
Operation mode
select bit
Function
b1 b0
1 0 : Pulse period / pulse width
measurement mode
RW
MR0
MR1
Measurement mode
select bit
b3 b2
0 0 : Pulse period measurement (Interval between
measurement pulse's falling edge to falling edge)
0 1 : Pulse period measurement (Interval between
measurement pulse's rising edge to rising edge)
1 0 : Pulse width measurement (Interval between
measurement pulse's falling edge to rising edge,
and between rising edge to falling edge)
1 1 : Inhibited
MR2
0 (Fixed to “0” in pulse period/pulse width measurement mode; i = 0, 3)
Nothing is assigned. ( i= 1, 2, 4, 5)
Write "0" when writing to this bit. If read, the value is indeterminate.
(Note 2)
(Note 3)
MR3
Timer Bi overflow
flag ( Note 1)
0 : Timer did not overflow
1 : Timer has overflowed
TCK0
TCK1
Count source
select bit
b7 b6
0 0 : f1
0 1 : f8
1 0 : f32
1 1 : fC32
Note 1: The Timer Bi overflow flag changes to “0” when the count start flag is “1” and a value is written to the
Timer Bi mode register. This flag cannot be set to “1” by software.
Note 2: Timer B0, Timer B3.
Note 3: Timer B1, Timer B2, Timer B4, Timer B5.
Fig. 1.66. Timer Bi mode register in pulse period/pulse width measurement mode
Count source
“H”
Measurement pulse
“L”
Reload register counter
transfer timing
Timing at which counter
reaches “0000 16”
“1”
Count start flag
“0”
Transfer
(indeterminate value)
(Note 1)
Transfer
(measured value)
(Note 1)
(Note 2)
Timer Bi interrupt
“1”
request bit
“0”
Timer Bi overflow flag “1”
“0”
Cleared to “0” when interrupt request is accepted, or cleared by software.
Note 1: Counter is initialized at completion of measurement.
Note 2: Timer has overflowed.
Fig. 1.67. Operation timing when measuring a pulse period
1-91