4. Port mode register 5 (PMR5)
Bit
7
WKP7
0
6
WKP6
0
5
WKP5
0
4
WKP4
0
3
WKP3
0
2
WKP2
0
1
WKP1
0
0
WKP0
0
Initial value
Read/Write
R/W
R/W
R/W
R/W
R/W
R/W
R/W
R/W
PMR5 is an 8-bit read/write register, controlling the selection of pin functions for port 5 pins.
Upon reset, PMR5 is initialized to H'00.
Bit n: P5n/WKPn/SEGn+1 pin function switch (WKPn)
When pin P5n/WKPn/SEGn+1 is not used as SEGn+1, these bits select whether the pin is used as P5
n
or WKPn.
Bit n
WKPn
Description
0
1
Functions as P5n I/O pin
Functions as WKPn input pin
(initial value)
(n = 7 to 0)
Note: For use as SEGn+1, see 13.2.1, LCD Port Control Register (LPCR).
8.6.3
Pin Functions
Table 8-15 shows the port 5 pin functions.
Table 8-15 Port 5 Pin Functions
Pin
Pin Functions and Selection Method
The pin function depends on bit WKPn in PMR5, bit PCR5n in PCR5, and bits
P57/WKP7/
SEG8 to
SEG8 to SGS3 to SGS0 in LPCR.
P50/WKP0/
SGS3 to SGS0
0***
1***
SEG1
WKPn
PCR5n
0
1
*
*
0
1
*
Pin function
P5n input pin P5n output pin
WKPn
input pin
SEGn+1
output pin
*: Don’t care
157