Pin Functions; P00 To P03 (Port 0); P20 To P23 (Port 2); P30 To P34 (Port 3) - NEC 78K0S/KB1+ User Manual

8-bit single-chip microcontrollers
Hide thumbs Also See for 78K0S/KB1+:
Table of Contents

Advertisement

2.2 Pin Functions

2.2.1 P00 to P03 (Port 0)

P00 to P03 function as a 4-bit I/O port. P00 to P03 can be set to input or output in 1-bit units using port mode
register 0 (PM0). Use of an on-chip pull-up resistor can be specified by pull-up resistor option register 0 (PU0).

2.2.2 P20 to P23 (Port 2)

P20 to P23 constitute a 4-bit I/O port, port 2. In addition to I/O port pins, these pins also have a function to input
analog signals to the A/D converter. These pins can be set to the following operation modes in 1-bit units.
(1) Port mode
P20 to P23 function as a 4-bit I/O port. Each bit of this port can be set to the input or output mode by using
port mode register 2 (PM2). In addition, an on-chip pull-up resistor can be connected to the port by using pull-
up resistor option register 2 (PU2).
(2) Control mode
P20 to P23 function as the analog input pins (ANI0 to ANI3) of the A/D converter. When using these pins as
analog input pins, refer to 10.6 Cautions for A/D converter (5) ANI0/P20 to ANI3/P23.

2.2.3 P30 to P34 (Port 3)

P30 to P33 constitute a 4-bit I/O port, port 3. In addition to I/O port pins, P30 and p31 also have functions to
input/output a timer signal, and input an external interrupt request signal.
P34 is a 1-bit input-only port. This pin is also used as a RESET pin, and when the power is turned on, this is the
reset function.
For settings of alternate function, refer to CHAPTER 18 OPTION BYTE. When using P34 as input port, pull up the
P34 pin by using external resistor.
P30 to P33 can be set to the following operation modes in 1-bit units.
(1) Port mode
P30 to P33 function as a 4-bit I/O port. Each bit of this port can be set to the input or output mode by using
port mode register 3 (PM3). In addition, an on-chip pull-up resistor can be connected to the port by using pull-
up resistor option register 3 (PU3).
P34 functions as a 1-bit input-only port.
(2) Control mode
P30 and P31 function to input/output signals to/from internal timers, and to input an external interrupt request
signal.
(a) INTP0 and INTP2
These are external interrupt request input pins for which the valid edge (rising edge, falling edge, or both
rising and falling edges) can be specified.
(b) TI000
This pin inputs an external count clock to 16-bit timer/event counter 00, or a capture trigger signal to the
capture registers (CR000 and CR010) of 16-bit timer/event counter 00.
(c) TI010
This pin inputs a capture trigger signal to the capture register (CR000) of 16-bit timer/event counter 00.
22
CHAPTER 2 PIN FUNCTIONS
User's Manual U17446EJ3V1UD

Advertisement

Table of Contents
loading

Table of Contents