deveopmen
Programmable I/O Port
Rev.B2 for proof reading
Mitsubishi Microcomputers
M32C/83 group
SINGLE-CHIP 16-BIT CMOS MICROCOMPUTER
311
(4) Function select register B
Figures 1.29.12 and 1.29.13 show the function select registers B.
This register selects the first peripheral function output and second peripheral function output when mul-
tiple peripheral function outputs are assigned to a pin. For pins with a third peripheral function, this regis-
ter selects whether to enable the function select register C, or output the second peripheral function.
Each bit of this register corresponds to each pin that has multiple peripheral function outputs assigned to it.
This register is enabled when the bits of the corresponding function select register A are set for peripheral
functions.
The bit 3 to bit 6 of function select register B3 is ignored bit for input peripheral function. When using DA0/DA1
and ANEX0/ANEX1, set related bit to
“
1
”
. When not using DA0/DA1 or ANEX0/ANEX1, set related bit to
“
0
”
.
(5) Function select register C
Figure 1.29.14 shows the function select register C.
This register is used to select the first peripheral function output and the third peripheral function output
when three peripheral function outputs are assigned to a pin.
This register is effective when the bits of the function select register A of the counterpart pin have selected
a peripheral function and when the function select register B has made effective the function select
register C.
The bit 7 (PSC_7) is assigned the key-in interrupt inhibit bit. Setting
“
1
”
in the key-in interrupt inhibit bit
causes no key-in interrupts regardless of the settings in the interrupt control register even if
“
L
”
is entered
in pins KI
0
to KI
3
. With
“
1
”
set in the key-in interrupt inhibit bit, input from a port pin cannot be effected
even if the port direction register is set to input mode.
(6) Pull-up control registers
Figures 1.29.15 to 1.29.17 show the pull-up control registers.
The pull-up control register can be set to apply a pull-up resistance to each block of 4 ports. When ports
are set to have a pull-up resistance, the pull-up resistance is connected only when the direction register is
set for input.
Since P0 to P5 operate as the bus in memory expansion mode and microprocessor mode, do not set the
pull-up control register. However, it is possible to select pull-up resistance presence to the usable port as
I/O port by setting.
(7) Port control register
Figure 1.29.18 shows the port control register.
This register is used to choose whether to make port P1 a CMOS port or an Nch open drain. In the Nch
open drain, the CMOS port
’
s Pch is kept always turned off so that the port P1 cannot be a complete open
drain. Thus the absolute maximum rating of the input voltage falls within the range from
“
- 0.3 V to Vcc +
0.3 V
”
.
The port control register functions similarly to the above. Also in the case in which port P1 can be used as
a port when the bus width in the full external areas comprises 8 bits in either microprocessor mode or in
memory expansion mode.