111
CHAPTER 5 PORT FUNCTIONS
User’s Manual U12697EJ3V0UM
5.2 Port Configuration
Ports include the following hardware.
Table 5-2. Port Configuration
Item
Configuration
Control registers
Port mode register (PMm: m = 0, 2 to 7, 12, 13)
Pull-up resistor option register (PUO, PUm: m = 0, 2, 3, 7, 12)
Ports
Total: 67 (input: 8, input/output: 59)
Pull-up resistors
Total: 57 (software control)
5.2.1 Port 0
Port 0 is a 6-bit I/O port with output latch. The P00 to P05 pins can specify the input mode/output mode in 1-bit
units with the port 0 mode register. A pull-up resistor can be connected via pull-up resistor option register 0, regardless
of whether the input mode or output mode is specified.
Port 0 also supports external interrupt request input as an alternate function.
RESET input sets port 0 to the input mode.
Figure 5-2 shows the block diagram of port 0.
Caution Even though port 0 is also used as an external interrupt input, when port 0 is not used as an
interrupt input pin, be sure to set interrupt disabled by using external interrupt rising edge enable
register 0 (EGP0) and external interrupt falling edge enable register 0 (EGN0) or setting the
interrupt enable flag (PMKn: n = 0 to 5) to 1. Otherwise, the interrupt request flag is set and
unintentional interrupt servicing may be executed when specifying prts to output mode and thus
changing the output level.