Chapter 7
I/O Port
Control Registers VII - 13
■ Port 2 Output Register (P2OUT: 0x0000A002) [8-bit access register]
■ Port 2 Input Register (P2IN: 0x0000A012) [8-bit access register]
■ Port 2 I/O Control Register (P2DIR: 0x0000A022) [8-bit access register]
bp 76543210
Flag P27O P26O P25O P24O P23O P22O P21O P20O
At reset 00000000
Access R/W R/W R/W R/W R/W R/W R/W R/W
bp Flag Description Set condition
7-0
P27O
to
P20O
Output data Output data
bp 76543210
Flag P27I P26I P25I P24I P23I P22I P21I P20I
At reset xxxxxxxx
Access RRRRRRRR
bp Flag Description Set condition
7-0
P27I
to
P20I
Input data ìInput data
bp 76543210
Flag P27D P26D P25D P24D P23D P22D P21D P20D
At reset 00000000
Access R/W R/W R/W R/W R/W R/W R/W R/W
bp Flag Description Set condition
7-0
P27D
to
P20D
I/O mode selection 0: Input mode
1: Output mode