English
Language : 

M16C Datasheet, PDF (102/262 Pages) Mitsubishi Electric Semiconductor – SINGLE-CHIP 16-BIT CMOS MICROCOMPUTER
Preliminary Specifications REV.B
Specifications in this manual are tentative and subject to change.
Mitsubishi microcomputers
M16C / 6N Group
SINGLE-CHIP 16-BIT CMOS MICROCOMPUTER
Timers’ functions for three-phase motor control
Three-phase motor driving waveform output mode (three-phase waveform mode)
Setting “1” in the mode select bit - bit 2 of three-phase PWM control register 0 (01C816) shown in Fig. 11-
1 - causes three-phase waveform mode that uses four timers A1, A2, A4, and B2 to be selected. As shown
in Figure 11-4, set timers A1, A2, and A4 in one-shot timer mode, set the trigger in timer B2, and set timer
B2 in timer mode using the respective timer mode registers.
Timer Ai mode register
b7 b6 b5 b4 b3 b2 b1 b0
01
10
Symbol
TA1MR
TA2MR
TA4MR
Address
039716
039816
039A16
Bit symbol
TMOD0
TMOD1
Bit name
Operation mode
select bit
MR0
Pulse output function
select bit
When reset
0016
0016
0016
Function
b1 b0
1 0 : One-shot timer mode
0 : Pulse is not output
(TAiOUT pin is a normal port pin)
1 : Pulse is output (Note 1)
(TAiOUT pin is a pulse output pin)
RW
MR1
MR2
External trigger select
bit (Note 2)
Trigger select bit
0 : Falling edge of TAiIN pin’s input signal (Note 3)
1 : Rising edge of TAiIN pin’s input signal (Note 3)
1 : Selected by event/trigger select
register
MR3
0 (Must always be 0 in one-shot timer mode)
TCK0
TCK1
Count source select bit
b7 b6
0 0 : f2
0 1 : f8
1 0 : f32
1 1 : fC32
Note 1: The settings of the corresponding port register and port direction register are invalid.
Note 2: Valid only when the TAiIN pin is selected by the event/trigger select bit
(addresses 038216 and 038316). If timer overflow is selected, this bit can be 1 or 0 .
Note 3: Set the corresponding port direction register to 0 .
Timer B2 mode register
b7 b6 b5 b4 b3 b2 b1 b0
0
00
Symbol
TB2MR
Address
039D16
When reset
00XX00002
Bit symbol
TMOD0
TMOD1
MR0
MR1
Bit name
Function
Operation mode select bit b1 b0
0 0 : Timer mode
Invalid in timer mode
Can be 0 or 1
MR2
MR3
TCK0
TCK1
0 (Fixed to 0 in timer mode ; i = 0)
Invalid in timer mode.
This bit can neither be set nor reset. When read in timer mode,
its content is indeterminate.
Count source select bit
b7 b6
0 0 : f2
0 1 : f8
1 0 : f32
1 1 : fC32
RW
Figure 11-4. Timer mode registers in three-phase waveform mode
102