
2007 Microchip Technology Inc.
DS39605F-page 9
PIC18F1220/1320
PORTB is a bidirectional I/O port. PORTB can be software
programmed for internal weak pull-ups on all inputs.
RB0/AN4/INT0
RB0
AN4
INT0
89
9
I/O
I
TTL
Analog
ST
Digital I/O.
Analog input 4.
External interrupt 0.
RB1/AN5/TX/CK/INT1
RB1
AN5
TX
CK
INT1
910
10
I/O
I
O
I/O
I
TTL
Analog
—
ST
Digital I/O.
Analog input 5.
EUSART asynchronous transmit.
EUSART synchronous clock (see related RX/DT).
External interrupt 1.
RB2/P1B/INT2
RB2
P1B
INT2
17
19
23
I/O
O
I
TTL
—
ST
Digital I/O.
Enhanced CCP1/PWM output.
External interrupt 2.
RB3/CCP1/P1A
RB3
CCP1
P1A
18
20
24
I/O
O
TTL
ST
—
Digital I/O.
Capture 1 input/Compare 1 output/PWM 1 output.
Enhanced CCP1/PWM output.
RB4/AN6/RX/DT/KBI0
RB4
AN6
RX
DT
KBI0
10
11
12
I/O
I
I/O
I
TTL
Analog
ST
TTL
Digital I/O.
Analog input 6.
EUSART asynchronous receive.
EUSART synchronous data (see related TX/CK).
Interrupt-on-change pin.
RB5/PGM/KBI1
RB5
PGM
KBI1
11
12
13
I/O
I
TTL
ST
TTL
Digital I/O.
Low-Voltage ICSP Programming enable pin.
Interrupt-on-change pin.
RB6/PGC/T1OSO/
T13CKI/P1C/KBI2
RB6
PGC
T1OSO
T13CKI
P1C
KBI2
12
13
15
I/O
O
I
O
I
TTL
ST
—
ST
—
TTL
Digital I/O.
In-Circuit Debugger and ICSP programming clock pin.
Timer1 oscillator output.
Timer1/Timer3 external clock output.
Enhanced CCP1/PWM output.
Interrupt-on-change pin.
RB7/PGD/T1OSI/
P1D/KBI3
RB7
PGD
T1OSI
P1D
KBI3
13
14
16
I/O
I
O
I
TTL
ST
CMOS
—
TTL
Digital I/O.
In-Circuit Debugger and ICSP programming data pin.
Timer1 oscillator input.
Enhanced CCP1/PWM output.
Interrupt-on-change pin.
VSS
5
5, 6
3, 5
P
—
Ground reference for logic and I/O pins.
VDD
14
15, 16 17, 19
P
—
Positive supply for logic and I/O pins.
NC
—
18
—
No connect.
TABLE 1-2:
PIC18F1220/1320 PINOUT I/O DESCRIPTIONS (CONTINUED)
Pin Name
Pin Number
Pin
Type
Buffer
Type
Description
PDIP/
SOIC
SSOP
QFN
Legend:
TTL =
TTL compatible input
CMOS = CMOS compatible input or output
ST
=
Schmitt Trigger input with CMOS levels
I
= Input
O=
Output
P
= Power
OD
=
Open-drain (no P diode to VDD)