PIC18F2XK20/4XK20 28/40/44-Pin Flash Microcontrollers with XLP Technology High-Performance RISC CPU Extreme Low-Power Management with XLP C Compiler Optimized Architecture: - Optional extended instruction set designed to Sleep Mode: < 100 nA 1.8V optimize re-entrant code Watchdog Timer: < 800 nA 1.8V Up to 1024 bytes Data EEPROM Timer1 Oscillator: < 800 nA 32 kHz and 1.8V Up to 64 Kbytes Linear Program Memory Addressing Analog Features Up to 3936 bytes Linear Data Memory Addressing Analog-to-Digital Converter (ADC) Module: Up to 16 MIPS Operation - 10-bit resolution, 13 External Channels 16-bit Wide Instructions, 8-bit Wide Data Path Priority Levels for Interrupts - Auto-acquisition capability 31-Level, Software Accessible Hardware Stack - Conversion available during Sleep 8 x 8 Single-Cycle Hardware Multiplier - 1.2V Fixed Voltage Reference (FVR) channel - Independent input multiplexing Flexible Oscillator Structure Analog Comparator Module: Precision 16 MHz Internal Oscillator Block: - Two rail-to-rail analog comparators - Factory calibrated to 1% - Independent input multiplexing - Software selectable frequencies range of Voltage Reference (CVREF) Module 31 kHz to 16 MHz - Programmable (% VDD), 16 steps - 64 MHz performance available using PLL - Two 16-level voltage ranges using VREF pins no external components required Four Crystal Modes up to 64 MHz Peripheral Highlights Two External Clock Modes up to 64 MHz 4X Phase Lock Loop (PLL) Up to 35 I/O Pins plus 1 Input-only Pin: Secondary Oscillator using Timer1 32 kHz - High-Current Sink/Source 25 mA/25 mA Fail-Safe Clock Monitor: - Three programmable external interrupts - Allows for safe shutdown, if peripheral clock - Four programmable interrupt-on-change stops - Eight programmable weak pull-ups - Programmable slew rate - Two-Speed Oscillator Start-up Capture/Compare/PWM (CCP) Module Special Microcontroller Features Enhanced CCP (ECCP) module: Operating Voltage Range: 1.8V to 3.6V - One, two or four PWM outputs Self-Programmable under Software Control - Selectable polarity Programmable 16-Level High/Low-Voltage - Programmable dead time Detection (HLVD) module: - Auto-shutdown and auto-restart - Interrupt on High/Low-Voltage Detection Master Synchronous Serial Port (MSSP) Module Programmable Brown-out Reset (BOR): - 3-wire SPI (supports all four modes) - With software enable option 2 -I C Master and Slave modes with address Extended Watchdog Timer (WDT): mask - Programmable period from 4 ms to 131s Enhanced Universal Synchronous Asynchronous Single-Supply 3V In-Circuit Serial Receiver Transmitter (EUSART) Module: Programming (ICSP) via Two Pins - Supports RS-485, RS-232 and LIN In-Circuit Debug (ICD) via Two Pins - RS-232 operation using internal oscillator - Auto-Wake-up on Break - Auto-Baud Detect 2010-2015 Microchip Technology Inc. DS40001303H-page 1PIC18F2XK20/4XK20 - PIC18F2XK20/4XK20 Family Types Program Memory Data Memory MSSP 10-bit CCP/ Timers (1) Device I/O A/D ECCP Comp. Flash Single-Word SRAM EEPROM Master 8/16-bit (2) SPI (ch) (PWM) 2 (bytes) Instructions (bytes) (bytes) I C PIC18F23K20 8K 4096 512 256 25 11 1/1 Y Y 1 2 1/3 PIC18F24K20 16K 8192 768 256 25 11 1/1 Y Y 1 2 1/3 PIC18F25K20 32K 16384 1536 256 25 11 1/1 Y Y 1 2 1/3 PIC18F26K20 64k 32768 3936 1024 25 11 1/1 Y Y 1 2 1/3 PIC18F43K20 8K 4096 512 256 36 14 1/1 Y Y 1 2 1/3 PIC18F44K20 16K 8192 768 256 36 14 1/1 Y Y 1 2 1/3 PIC18F45K20 32K 16384 1536 256 36 14 1/1 Y Y 1 2 1/3 PIC18F46K20 64k 32768 3936 1024 36 14 1/1 Y Y 1 2 1/3 Note 1: One pin is input-only. 2: Channel count includes internal Fixed Voltage Reference channel. Note: For other small form-factor package availability and marking information, please visit