MC80F0304/08/16
November 4, 2011 Ver 2.12
49
9.4 R3 and R3IO register
R3 is a 6-bit CMOS bidirectional I/O port (address 0C6
H
). Each
I/O pin (except R35) can independently used as an input or an
output through the R3IO register (address 0C7
H
). R35 is an input
only port. When R30 through R35 pins are used as input ports, an
on-chip pull-up resistor can be connected to them in 1-bit units
with a pull-up selection register 3 (PU3). R30 through R34 pins
can be used to open drain output port by setting the corresponding
bit of the open drain selection register 1 (R3OD).
In addition, Port R3 is multiplexed with alternate functions. R30
R31,and R32 can be used as ADC input channel 13,14 and 15 by
setting ADCM to enable ADC and select channel 13,14 and 15.
R33, R34 and R35 is multiplexd with X
IN
, X
OUT
, and RESET pin
.
R2 Data Register
R2
ADDRESS: 0C4
H
RESET VALUE: 00
H
R25 R24 R23 R22 R21
Port Direction
R2 Direction Register
R2IO
ADDRESS: 0C5
H
RESET VALUE: 00
H
0: Input
1: Output
Input / Output data
R2 Pull-up
PU2
ADDRESS: 0FE
H
RESET VALUE: 00
H
Selection Register
0: Disable
1: Enable
Pull-up Resister Selection
R2 Open Drain
R2OD
ADDRESS: 0CA
H
RESET VALUE: 00
H
Selection Register
0: Disable
1: Enable
Open Drain Resister Selection
R27 R26
R20
Port Pin
Alternate Function
R30
R31
R32
AN13 (ADC input channel 13)
AN14 (ADC input channel 14)
AN15 (ADC input channel 15)