
CHAPTER 4 PORT FUNCTIONS
User’s Manual U19780EJ2V0UD
100
4.2.5 Port 4
78K0/KB2-A 78K0/KC2-A
P40/RTCCL/RTCDIV
P41/RTC1HZ
−
P42/PCL/SSI10/INTP9
Port 4 is an I/O port with an output latch. Port 4 can be set to the input mode or output mode in 1-bit units using
port mode register 4 (PM4). When the P40 to P42 pins are used as an input port, use of an on-chip pull-up resistor
can be specified in 1-bit units by pull-up resistor option register 4 (PU4).
This port can also be used for external interrupt request input, clock output, real-time counter clock output, and chip
select input for serial interface.
Reset signal generation sets port 4 to input mode.
Figures 4-14 and 4-15 show block diagrams of port 4.
Figure 4-14. Block Diagram of P40 and P41
P40/RTCCL/RTCDIV,
P41/RTC1HZ
WR
PU
RD
WR
PORT
WR
PM
PU40, PU41
PM40, PM41
V
DD
P-ch
PU4
PM4
P4
Internal bus
Selector
Output latch
(P40, P41)
Alternate
function
P4:
Port register 4
PU4:
Pull-up resistor option register 4
PM4:
Port mode register 4
RD: Read
signal
WR
××
: Write
signal