HMS81004E/08E/16E/24E/32E
JUNE 2001 Ver 1.00
31
(1) R1 I/O Data Direction Register (R1DD)
R1 I/O Data Direction Register (R1DD) is 8-bit register,
and can assign input state or output state to each bit. If
R1DD is “1”, port R1 is in the output state, and if “0”, it is
in the input state. R1DD is write-only register. Since
R1DD is initialized as “00h” in reset state, the whole port
R1 becomes input state.
(2) R1 Data Register (R1)
R1 data register (R1) is 8-bit register to store data of port
R1. When set as the output state by R1DD, and data is
written in R1, data is outputted into R1 pin. When set as
the input state, input state of pin is read. The initial value
of R1 is unknown in reset state.
(3) R1 Open drain Assign Register (R1ODC)
R1 Open Drain Assign Register (R1ODC) is 8bit register,
and can assign R1 port as open drain output port each bit,
if corresponding port is selected as output. If R1ODC is
selected as “1”, port R1 is open drain output, and if select-
ed as “0”, it is push-pull output. R1ODC is write-only reg-
ister and initialized as “00h” in reset state.
(4) R1 Port Mode Register (PMR1)
R1 Port Mode Register (PMR1) is 8-bit register, and can
assign the selection mode for each bit. When set as “0”,
corresponding bit of PMR1 acts as port R1 selection mode,
and when set as “1”, it becomes function selection mode.
PMR1 is write-only register and initialized as “00h” in re-
set state. Therefore, becomes Port selection mode. Port
R1 can be I/O port by manipulating each R1DD bit, if cor-
responding PMR1 bit is selected as “0”.
(5) R1 Pull-up Control Register (R1PC)
R1 Pull-up Control Register (R1PC) is 8-bit register and
can control pull-up on or off each bit, if corresponding port
is selected as input. If R1PC is selected as “1”, pull-up ia
disabled and if selected as “0”, it is enabled. R1PC is write-
only register and initialized as “00h” in reset state. The
R1 Data Register (R/W)
R1
ADDRESS : 0C2
H
RESET VALUE : Undefined
R17 R16 R15 R14 R13 R12 R11 R10
Port Direction
0: Input
1: Output
R1 Direction Register (W)
R1DD
ADDRESS : 0C3
RESET VALUE : 00
H
Pull-up select
1: Without pull-up
0: With pull-up
R1 Pull-up Control Register (W)
R1PC
ADDRESS : 0F9
RESET VALUE : 00
H
Open drain select
0: Push-pull
1: Open drain
R1 Open drain Assign Register (W)
P1ODC
ADDRESS : 0DE
RESET VALUE : 00
H
Mode select
0: Port R1 selection
1: Function selection
R1 Port Mode Register (W)
PMR1
ADDRESS : 0C9
RESET VALUE : 00
H
Pin Name
PMR1
Selection
Mode
Remarks
T0S
0
R17 (I/O)
-
1
T0 (O)
Timer0
T1S
0
R16 (I/O)
-
1
T1 (O)
Timer1
T2S
0
R15 (I/O)
-
1
T2 (O)
Timer2
ECS
0
R14 (I/O)
-
1
EC (I)
Timer0 Event
INT2S
0
R12 (I/O)
1
INT2 (I)
Timer0 Input Cap-
ture
INT1S
0
R11 (I/O)
1
INT1 (I)
Table 9-1 Selection mode of PMR1