140
7.3.4 Input Pull-Up Transistors
Port 2 has built-in MOS input pull-up transistors that can be controlled by software. These input
pull-up transistors can be turned on and off individually.
When a P2PCR bit is set to 1 and the corresponding P2DDR bit is cleared to 0, the input pull-up
transistor is turned on.
The input pull-up transistors are turned off by a reset and in hardware standby mode. In software
standby mode they retain their previous state.
Table 7-4 summarizes the states of the input pull-up transistors in each mode.
Table 7-4 Input Pull-Up Transistor States (Port 2)
Mode
Reset
Hardware Standby
Mode
Software Standby
Mode
Other Modes
1
3
Off
Off
Off
Off
5
6
7
Off
Off
On/off
On/off
Legend
Off:
The input pull-up transistor is always off.
On/off:
The input pull-up transistor is on if P2PCR = 1 and P2DDR = 0. Otherwise, it is off.