32171 Group is a 32-bit, single-chip RISC microcomputer
with built-in flash memory, which was developed for use in
general industrial and household equipment.
To make full use of microcomputer built-in mass volume
flash memory, this microcomputer contains a variety of peripheral functions ranging from two independent blocks of
16-channel A-D converters to 37-channel multifunction timers, 10-channel DMAs, 3-channel serial I/Os, and 1-channel
real time debugger. Also included 1-channel Full-CAN modules and JTAG (boundary scan facility).
With lower power consumption and low noise characteristics
also considered, these microcomputers are ideal for embedded equipment applications.
Features
M32R RISC CPU core
• Uses the M32R family RISC CPU core (Instruction set
common to all microcomputers in the M32R family)
• Five-stage pipelined processing
• Sixteen 32-bit general-purpose registers
• 16-bit/32-bit instructions implemented
• DSP function instructions (sum-of-products calculation
using 56-bit accumulator)
To meet the need for use at high temperatures, the microcomputer is designed to be able to operate in the temperature
range of -40 to +125oC when CPU clock operating
frequency = 32 MHz. When CPU clock operating frequency =
40 MHz, the microcomputer can be used in the temperature
o
range of -40 to +85
Note: This does not guarantee continuous operation at
The M32171 Group uses the M32R RISC CPU core, and has
an instruction set which is common to all microcomputers in
the M32R family.
Instructions are processed in five pipelined stages consisting
of instruction fetch, decode, execution, memory access, and
write back. Thanks to its “out-of-order-completion” mechanism,
the M32R CPU allows for clock cycle efficient, instruction execution control.
The M32R CPU internally has sixteen 32-bit general-purpose
registers. The instruction set consists of 83 discrete instructions, which come in either a 16-bit instruction or a 32-bit instruction format. Use of the 16-bit instruction format helps to
reduce the code size of a program. Also, the availability of 32bit instructions facilitates programming and increases the performance at the same clock speed, as compared to
architectures with segmented address spaces.
Sum-of-products instructions comparable to DSP
The M32R CPU contains a multiplier/accumulator that can
execute 32 bits × 16 bits in one cycle. Therefore, it executes a
32 bit × 32 bit integer multiplication instruction in three cycles.
Also, the M32R CPU supports the following four sum-of-products instructions (or multiplication instructions) for DSP function use.
(4) All 32 register bits × 16 low-order register bits
Furthermore, the M32R CPU has instructions for rounding the
value stored in the accumulator to 16 or 32 bits, and instructions for shifting the accumulator value to adjust digits before
storing in a register. Because these instructions also can be
executed in one cycle, DSP comparable data processing capability can be obtained by using them in combination with
high-speed data transfer instructions such as Load & Address
Update or Store & Address Update.
Address space
The M32171 Group’s logical addresses are always handled in
32 bits, providing 4 Gbytes of linear address space. The
M32171 Group’s address space consists of the following.
User space
A 2-Gbyte area from H’0000 0000 to H’7FFF FFFF is the user
space. Located in this space are the user ROM area, external
extended area, internal RAM area, and SFR (Special Function Register) area (internal peripheral I/O registers). Of
these, the user ROM area and external extended area are located differently depending on mode settings.
Boot program space
A 1-Gbyte area from H’8000 0000 to H’BFFF FFFF is the boot
program area. This space contains the on-board programming program (boot program) used in blank state by the internal flash memory.
System space
A 1-Gbyte area from H’C000 0000 to H’FFFF FFFF is the
system area. This space is reserved for use by development
tools such as an in-circuit emulator and debug monitor, and
cannot be used by the user.
Three operation modes
The M32170 and M32174 Group has three operation modes:
single-chip mode, external extended mode, and processor
mode. These operation modes are changed from one to another by setting the MOD0 and MOD1 pins.
PowerVCCEPower supply—Supplies power (5 V or 3.3V) to external I/O ports.
supplyVCCIPower supply—Supplies power (3.3 V) to the internal logic.
VDDRAM power supply —nternal RAM backup power supply (3.3 V).
FVCCFlash power supply —Internal flash memory backup power supply (3.3 V).
VSSGround —Connect all VSS pins to ground (GND).
ClockXIN,ClockInputClock input/output pins. These pins contain a PLL-based
XOUTOutputfrequency multiply-by-4, so input the clock whose frequency is quarter
the operating frequency. (XIN input = 10 MHz when CPU clock operates
at 40 MHz)
BCLK /System clockOutput
______
WRexternal inpout clock. (BCLK output = 20 MHz when CPU clock operates at 40
When this signal is System Clock(BCLK), it outputs a clock whose is twice
MHz). Use this clock when circuits are synchronized externally.
When this signal is Write(WR), during external write access it indicates the
valid data on the data bus to transfer.
______
that of
OSC-VCCPower supply—Power supply to the PLL circuit. Connect OSC-VCC to the power supply(3.3V)
OSC-VSSGround —Connect OSC-VSS to ground.
VCNTPLL controlInputThis pin controls the PLL circuit. Connect a resistor and capacitor to this pin.
Reset
ModeMOD0ModeInputThese pins set an operation mode.
AddressA12-A30AddressOutput19 lines of address bus (A12-A30) are provided to accommodate two
busbus
Data busDB0-DB15Data busInput/outputThis 16-bit data bus connects to external device.
______
RESETResetInputThis pin resets the internal circuits.
channels of 1 MB memory space (max.) connected external to the chip.
A31 is not output.
In the write cycle, of the 16-bit data bus the valid byte positions to write are
output as BHW/ BHE and BLW/ BLE. In read cycle, data on the entire 16-bit
data bus is read. However, only the data at the valid byte positions are
transferred to the M32R’s internal circuit.
_________ ________________ _______
Note: FP pin should be “H” level in Boot Mode.
8
2001-5-14 Rev.1.0
Table 5 Description of Pin Function (2/4)
Mitsubishi Microcomputers
32171 Group
SINGLE-CHIP 32-BIT CMOS MICROCOMPUTER
TypePin typeDescriptionInput/Output Function
Bus
___
CS0,ChipOutputChip select signals for external devices.
controlCS1select
__
RDReadOutputThis signal is output when reading external devices.
___
_______
BHW/ BHEByte highOutputIndicates the byte positions to which valid are transferred when writing to
___
write
_______
BLW/ BLEByte lowOutput
external devices.BHW/ BHE and BLW/ BLE correspond to the upper address
side(D0-D7 effective) and the lower address side(D8-D15 effective),respectivel.
write
____
WAITWaitInput
_________
If WAIT input is low when the M32R accesses external devices, the wait cycle
extended.
_____
HREQHoldInputThis pin is used by an external device to request control of the external bus.
____
request
HACKHoldOutputThis signal indicates to the external device that the M32R has entered a hold
The M32R goes to a hold state when HREQ input is pulled low.
acknowledgestate and relinquished control of the external bus.
Multijunction
TIN0, TIN3Timer inputInputInput pins for multijunction timer.
timerTIN16-TIN23
TO0Timer outputOutputOutput pins for multijunction timer.
-TO20
TCLK0Timer clockInputClock input pins for multijunction timer.
-TCLK3
________ _______________ _______
__________
A-DAVCC0,Analog power –AVCC0 is the power supply for the A-D0 converters.Connect AVCC0
converter
upply
to the power supply (5V or 3.3V).
AVSS0Analog ground –AVSS0 is the analog ground for the A-D0 converters. Connect AVCC0 to ground
AD0IN0Analog inputInput16-channel analog input pin for A-D0 converter.
-AD0IN15
VREF0ReferenceInputVREF0 is the reference voltage input pin (5V or 3.3V) for the A-D0 converters.
voltage input
___
Interrupt
SBISystemInputSystem break interrupt(SBI) input pin of the interrupt controller.
controllerbreak
interrupt
9
2001-5-14 Rev.1.0
SINGLE-CHIP 32-BIT CMOS MICROCOMPUTER
Table 6 Description of Pin Functions (3/4)
TypePin nameDescription Input/outputFunction
SerialSCLKI0/UART transmit/ Input/outputWhen channel 0 is in UART mode:
I/O
SCLKO0receive clock Clock output derived from BRG output by dividing it by 2
output or CSIO
transmit/receiveWhen channel 0 is in CSIO mode:
clock Transmit/receive clock input when external clock is selected
input/output Transmit/receive clock output when internal clock is selected
SCLKI1/UART transmit/ Input/outputWhen channel 1 is in UART mode:
SCLKO1receive clock Clock output derived from BRG output by dividing it by 2
output or CSIO
transmit/receiveWhen channel 1 is in CSIO mode:
clock Transmit/receive clock input when external clock is selected
input/output Transmit/receive clock output when internal clock is selected
Mitsubishi Microcomputers
32171 Group
TXD0Transmit dataOutputTransmit data output pin for serial I/O channel 0
RXD0Receive dataInputReceive data input pin for serial I/O channel 0
TXD1Transmit dataOutputTransmit data output pin for serial I/O channel 1
RXD1Receive dataInputReceive data input pin for serial I/O channel 1
TXD2Transmit dataOutputTransmit data output pin for serial I/O channel 2
RXD2Receive dataInputReceive data input pin for serial I/O channel 2
Real-Time
Debugger
Flash-FPFlash protectInputThis pin protects the flash memory against E/W in hardware.
only
CANCTXTransmit dataOutputData output pin from CAN module.
RTDTXDTransmit dataOutputSerial data output pin of the real-time debugger
RTDRXDReceive dataInputSerial data input pin of the real-time debugger
RTDCLKClock inputInputSerial data transmit/receive clock input pin of the real-time debugger
RTDACKAcknowledgeOutputThis pin outputs a low pulse synchronously with the real-time debugger’s
first clock of serial data output word. The low pulse width indicates the
type of the command/data the realtime debugger has received.
CRXReceive dataInputData input pin to CAN module.
JTAGJTMSTest modeInputTest select input for controlling the test circuit’s state transition
JTCKClockInputClock input to the debugger module and test circuit.
JTRSTTest resetInput Test reset input for initializing the test circuit asynchronously.
JTDOSerial outputOutputSerial output of test instruction code or test data.
JTDISerial inputInputSerial input of test instruction code or test data.
10
2001-5-14 Rev.1.0
SINGLE-CHIP 32-BIT CMOS MICROCOMPUTER
Table 7 Description of Pin Functions (4/4)
TypePin nameDescriptionInput/outputFunction
Input/
output
port
(Note)
P00-P07Input/output port 0Input/outputProgrammable input/output port.
P10-P17Input/output port 1Input/outputProgrammable input/output port.
P20-P27Input/output port 2Input/outputProgrammable input/output port.
P30-P37Input/output port 3Input/outputProgrammable input/output port.
P41-P47Input/output port 4Input/outputProgrammable input/output port.
P61-P64Input/output port 6Input/outputProgrammable input/output port.
(However, P64 is an input-only port)
P70-P77Input/output port 7Input/outputProgrammable input/output port.
P82-P87Input/output port 8Input/outputProgrammable input/output port.
P93-P97Input/output port 9Input/outputProgrammable input/output port.
Mitsubishi Microcomputers
32171 Group
P100Input/output port 10Input/outputProgrammable input/output port.
-P107
P110Input/output port 11Input/outputProgrammable input/output port.