PIC16(L)F720/721
20-Pin Flash Microcontrollers
Devices Included In This Data Sheet:
• PIC16F720
• PIC16F721
• PIC16LF720
• PIC16LF721
Extreme Low-Power (XLP) Features:
• Sleep Current:
- 40 nA @ 1.8V, typical
• Low-Power Watchdog Timer Current:
- 500 nA @ 1.8V, typical
High-Performance RISC CPU:
• Only 35 Instructions to Learn:
- All single-cycle instructions except branches
• Operating Speed:
- DC – 16 MHz oscillator/clock input
- DC – 250 ns instruction cycle
• Up to 4K x 14 Words of Flash Program Memory
• Up to 256 bytes of Data Memory (RAM)
• Interrupt Capability
• 8-Level Deep Hardware Stack
• Direct, Indirect and Relative Addressing modes
• Processor Self-Write/Read access to Program
Memory
Peripheral Features:
• Up to 17 I/O Pins and One Input-only Pin:
- High-current source/sink for direct LED drive
- Interrupt-on-change pins
- Individually programmable weak pull-ups
• A/D Converter:
- 8-bit resolution
- 12 channels
- Selectable Voltage reference
• Timer0: 8-Bit Timer/Counter with 8-Bit
Programmable Prescaler
• Enhanced Timer1
- 16-bit timer/counter with prescaler
- External Gate Input mode with toggle and
Single Shot modes
- Interrupt-on-gate completion
• Timer2: 8-Bit Timer/Counter with 8-Bit Period
Register, Prescaler and Postscaler
• Capture, Compare, PWM module (CCP)
- 16-bit Capture, max resolution 12.5 ns
- 16-bit Compare, max resolution 250 ns
- 10-bit PWM, max frequency 15 kHz
• Addressable Universal Synchronous
Asynchronous Receiver Transmitter (AUSART)
• Synchronous Serial Port (SSP)
- SPI (Master/Slave)
- I
2
C (Slave) with Address Mask
Memory
• High-Endurance Flash Data Memory
- 128B of nonvolatile data storage
- 100K erase/write cycles
Special Microcontroller Features:
• Precision Internal Oscillator:
- 16 MHz or 500 kHz operation
- Factory calibrated to ±1%, typical
- Software tunable
- Software selectable ÷1, ÷2, ÷4 or ÷8 divider
• Power-Saving Sleep mode
• Industrial and Extended Temperature Range
• Power-on Reset (POR)
• Power-up Timer (PWRT)
• Brown-out Reset (BOR)
• Multiplexed Master Clear with Pull-up/Input Pin
• Programmable Code Protection
• In-Circuit Serial Programming
TM
(ICSP
TM
) via Two
Pins
• Wide Operating Voltage Range:
- 1.8V to 5.5V (PIC16F720/721)
- 1.8V to 3.6V (PIC16LF720/721)
2010-2015 Microchip Technology Inc.
DS40001430F-page 1
PIC16(L)F720/721
PIC16(L)F72X Family Types
High-Endurance Flash
Memory (bytes)
Program Memory
Flash (words)
Data Sheet Index
CapSense (ch)
8-bit ADC (ch)
SSP (I
2
C/SPI)
Data SRAM
(bytes)
Timers
(8/16-bit)
AUSART
Debug
(1)
I/O’s
(2)
CCP
Device
PIC16(L)F707
(1)
8192
363
0
36 14 32
4/2
1
1
PIC16(L)F720
(2)
2048
128
128
18 12 —
2/1
1
1
PIC16(L)F721
(2)
4096
256
128
18 12 —
2/1
1
1
PIC16(L)F722
(4)
2048
128
0
25 11 8
2/1
1
1
PIC16(L)F722A
(3)
2048
128
0
25 11 8
2/1
1
1
PIC16(L)F723
(4)
4096
192
0
25 11 8
2/1
1
1
PIC16(L)F723A
(3)
4096
192
0
25 11 8
2/1
1
1
PIC16(L)F724
(4)
4096
192
0
36 14 16
2/1
1
1
PIC16(L)F726
(4)
8192
368
0
25 11 8
2/1
1
1
PIC16(L)F727
(4)
8192
368
0
36 14 16
2/1
1
1
Note 1:
I - Debugging, Integrated on Chip; H - Debugging, Requires Debug Header.
2:
One pin is input-only.
Data Sheet Index:
(Unshaded devices are described in this document.)
1:
DS41418
PIC16(L)F707 Data Sheet, 40/44-Pin Flash, 8-bit Microcontrollers
2:
DS41430
PIC16(L)F720/721 Data Sheet, 20-Pin Flash, 8-bit Microcontrollers
3:
DS41417
PIC16(L)F722A/723A Data Sheet, 28-Pin Flash, 8-bit Microcontrollers
4:
DS41341
PIC16(L)F72X Data Sheet, 28/40/44-Pin Flash, 8-bit Microcontrollers
2
1
1
2
2
2
2
2
2
2
I
I
I
I
I
I
I
I
I
I
Y
Y
Y
Y
Y
Y
Y
Y
Y
Y
Note:
For other small form-factor package availability and marking information, please visit
http://www.microchip.com/packaging
or contact your local sales office.
DS40001430F-page 2
2010-2015 Microchip Technology Inc.
XLP
PIC16(L)F720/721
PIN DIAGRAMS
FIGURE 1:
20-PIN DIAGRAM FOR PIC16(L)F720/721
V
DD
RA5/T1CKI/CLKIN
RA4/AN3/T1G/CLKOUT
RA3/MCLR/V
PP
1
2
PIC16(L)F720/721
3
4
6
7
8
9
10
20
19
18
17
16
15
14
13
12
11
V
SS
RA0/AN0/ICSPDAT
RA1/AN1/ICSPCLK
RA2/AN2/T0CKI/INT
RC0/AN4
RC1/AN5
RC2/AN6
RB4/AN10/SDI/SDA
RB5/AN11/RX/DT
RB6/SCK/SCL
PDIP, SOIC, SSOP
RC5/CCP1 5
RC4
RC3/AN7
RC6/AN8/SS
RC7/AN9/SDO
RB7/TX/CK
Pin Diagrams –
20-PIN DIAGRAM FOR PIC16(L)F720/721
QFN (4x4)
RA4/AN3/T1G/CLKOUT
RA5/T1CKI/CLKIN
V
DD
20 19 18 17 16
RA3/MCLR/V
PP
1
RC5/CCP1
RC4
2
15 RA1/AN1/ICSPCLK
14 RA2/AN2/T0CKI/INT
12
3
PIC16(L)F720/721
13 RC0/AN4
RC1/AN5
5
6
RC7/AN9/SDO
7
RB7/TX/CK
8
RB6/SCK/SCL
9 10
RB4/AN10/SDI/SDA
RB5/AN11/RX/DT
11 RC2/AN6
RC3/AN7 4
RC6/AN8/SS
2010-2015 Microchip Technology Inc.
V
SS
RA0/AN0/ICSPDAT
DS40001430F-page 3
PIC16(L)F720/721
TABLE 1:
20-PIN ALLOCATION TABLE (PIC16(L)F720/721)
20-Pin PDIP/SOIC/
SSOP
20-Pin QFN
AUSART
Interrupt
Pull-up
Timers
RA0
RA1
RA2
RA3
RA4
RA5
RB4
RB5
RB6
RB7
RC0
RC1
RC2
RC3
RC4
RC5
RC6
RC7
V
DD
Vss
19
18
17
4
3
2
13
12
11
10
16
15
14
7
6
5
8
9
1
20
16
15
14
1
20
19
10
9
8
7
13
12
11
4
3
2
5
6
18
17
AN0
AN1
AN2
—
AN3
—
AN10
AN11
—
—
AN4
AN5
AN6
AN7
—
—
AN8
AN9
—
—
—
—
T0CKI
—
T1G
T1CKI
—
—
—
—
—
—
—
—
—
—
—
—
—
—
—
—
—
—
—
—
—
—
—
—
—
—
—
—
—
CCP1
—
—
—
—
—
—
—
—
—
—
—
RX/DT
—
TX/CK
—
—
—
—
—
—
—
—
—
—
—
—
—
—
—
—
SDI/SDA
—
SCK/SCL
—
—
—
—
—
—
—
SS
SDO
—
—
IOC
IOC
INT/IOC
IOC
IOC
IOC
IOC
IOC
IOC
IOC
—
—
—
—
—
—
—
—
—
—
Y
Y
—
Y
Y
Y
Y
Y
Y
Y
—
—
—
—
—
—
—
—
—
—
ICSPDAT
ICSPCLK
—
MCLR/V
PP
CLKOUT
CLKIN
—
—
—
—
—
—
—
—
—
—
—
—
V
DD
V
SS
DS40001430F-page 4
2010-2015 Microchip Technology Inc.
Basic
CCP
SSP
A/D
I/O
PIC16(L)F720/721
Table of Contents
Device Overview ................................................................................................................................................................................... 7
Memory Organization .......................................................................................................................................................................... 11
Resets ................................................................................................................................................................................................. 24
Interrupts ............................................................................................................................................................................................. 34
Low Dropout (LDO) Voltage Regulator ............................................................................................................................................... 41
I/O Ports .............................................................................................................................................................................................. 42
Oscillator Module ................................................................................................................................................................................ 62
Device Configuration ........................................................................................................................................................................... 67
Analog-to-Digital Converter (ADC) Module ......................................................................................................................................... 71
Fixed Voltage Reference .................................................................................................................................................................... 80
Temperature Indicator Module ............................................................................................................................................................ 82
Timer0 Module .................................................................................................................................................................................... 83
Timer1 Module with Gate Control ....................................................................................................................................................... 86
Timer2 Module .................................................................................................................................................................................... 98
Capture/Compare/PWM (CCP) Module ............................................................................................................................................ 100
Addressable Universal Synchronous Asynchronous Receiver Transmitter (AUSART) .................................................................... 109
SSP Module Overview ...................................................................................................................................................................... 129
Flash Program Memory Self-Read/Self-Write Control ...................................................................................................................... 151
Power-Down Mode (Sleep) ............................................................................................................................................................... 158
In-Circuit Serial Programming™ (ICSP™) ........................................................................................................................................ 160
Instruction Set Summary ................................................................................................................................................................... 161
Development Support ....................................................................................................................................................................... 170
Electrical Specifications .................................................................................................................................................................... 174
DC and AC Characteristics Graphs and Charts ................................................................................................................................ 200
Packaging Information ...................................................................................................................................................................... 220
Appendix A: Data Sheet Revision History ......................................................................................................................................... 230
Appendix B: Migrating From Other PIC® Devices ............................................................................................................................ 230
The Microchip Website ..................................................................................................................................................................... 231
Customer Change Notification Service ............................................................................................................................................. 231
Customer Support ............................................................................................................................................................................. 231
Product Identification System ........................................................................................................................................................... 232
2010-2015 Microchip Technology Inc.
DS40001430F-page 5