PIC18F87K22-I/PT - 8-Bit 64MHz 128KB Flash MCU 80-TQFP | Microchip
MPN: PIC18F87K22-I/PT ✓ Active| Qty | Unit Price | Extended |
|---|---|---|
| 1 | $8.42 | $8.42 |
| 10 | $7.51 | $75.10 |
| 100 | $6.4 | $640.00 |
| 500 | $5.83 | $2,915.00 |
| 1,000 | $5.27 | $5,270.00 |
PIC18F87K22-I/PT Overview
An 8-bit microcontroller (MCU) is a single-chip computer that executes instructions on 8-bit data paths. Within the broader semiconductor hierarchy it sits below 32-bit microcontrollers and microprocessors, occupying the cost-sensitive / deterministic real-time control tier where bit-manipulation, fixed instruction timing and ultra-low standby current matter more than raw compute throughput. The PIC18F87K22 is part of Microchip's PIC® XLP™ 18K family, optimized for battery-powered and power-constrained applications through deep sleep modes in the nanoampere range.
Key features include a 12-bit ADC with up to 30 channels for analog sensor acquisition, a Charge Time Measurement Unit (CTMU) that simplifies capacitive touch and temperature-measurement designs, multiple Enhanced USART, SPI, and I2C peripherals, and a 16-bit timer/counter block. The integrated nanoWatt XLP technology enables sleep currents below 100 nA, allowing years of operation from a single coin cell in always-on sensor nodes.
Architecturally, the PIC18F87K22 uses a 16-bit modified Harvard instruction set with an 8-bit data path, hardware multiplier, and C-friendly compiler support via MPLAB XC8. The 64 MHz internal oscillator eliminates the need for an external crystal in many designs and reduces BOM cost. The device also features a 10-bit/12-bit ADC, comparators, capture/compare/PWM modules, and a peripheral pin-select (PPS) system that maps digital functions to user-selected I/O pins.
Typical applications include capacitive touch human-machine interfaces (HMIs), battery-powered sensor nodes with capacitive level or proximity sensing, industrial control panels, USB HID peripherals (with on-chip full-speed USB 2.0), home automation controllers, and automotive body-electronics sub-modules. Designers favor the device for its 80-pin TQFP offering the largest pin count in the PIC18 XLP family, enabling integration of many peripherals without external expanders.
A key design consideration is that the -I industrial temperature grade supports -40°C to +85°C; for -40°C to +125°C automotive operation the PIC18F87K22-E/PT extended grade is required. Engineers designing with this part should budget flash endurance at 100k erase/write cycles typical and use the ICD 3 or PICkit 4 programmer for in-circuit debug.
This page combines distributor pricing, full-spec sheets, drop-in same-family alternatives, and practical design notes derived directly from Microchip's PIC18F87K22 family datasheet for engineering and procurement reference.
Drop-in alternatives for PIC18F87K22-I/PT — same package, pin-to-pin compatible. Different-package parts requiring PCB rework are excluded.
Variants in this series
Same-series models that are drop-in compatible with PIC18F87K22-I/PT (same form factor and footprint) — differing in Package, Timers, ADC, Operating Temperature, I/O Pins.
Quick Comparison Tool — Select alternative parts for side-by-side comparison:
PIC18F87K22-E/PT
✅ Drop-In✓ In Stock
$7.65 / Unit
View Datasheet →PIC18F87K22T-I/PT
✅ Drop-In✓ In Stock
$7.95 / Unit
View Datasheet →PIC18F86K22-I/PT
✅ Drop-In✓ In Stock
$4.21 / Unit
View Datasheet →PIC18F8722-I/PT
✅ Drop-In✓ In Stock
$6.5 / Unit
View Datasheet →PIC18F87J94-I/PT
✅ Drop-In✓ In Stock
$6.88 / Unit
View Datasheet →PIC18F87J11-I/PT
✅ Drop-In✓ In Stock
$6.3 / Unit
View Datasheet →PIC18F87K22-I/PT Maximum Ratings & Electrical Characteristics
| Core Architecture | PIC 8-bit (16-bit modified Harvard instruction set) |
| Family | PIC® XLP™ 18K |
| Maximum CPU Frequency | 64 MHz |
| Program Memory (Flash) | 128 KB (64K x 16) |
| Data RAM | 4 KB |
| Data EEPROM | 1 KB |
| Supply Voltage Range | 1.8 V to 5.5 V (4.2 V to 5.5 V for -I grade full-speed operation) |
| I/O Pins | 70 |
| ADC | 12-bit, up to 30 channels |
| Comparators | Yes |
| Timers | 16-bit and 8-bit timer blocks |
| CCP/ECCP Modules | Yes (Capture/Compare/PWM) |
| Communication | EUSART, SPI, I2C, USB 2.0 Full-Speed |
| Charge Time Measurement Unit (CTMU) | Yes (capacitive touch support) |
| Peripheral Pin Select (PPS) | Yes |
| nanoWatt XLP Technology | Yes (sleep current < 100 nA typical) |
| Operating Temperature | -40 C to +85 C (industrial, -I grade) |
| Package | 80-pin TQFP (PT), 12 x 12 mm |
| Mounting Type | Surface Mount |
| MSL Level | 3 (per JEDEC J-STD-020) |
| RoHS Status | Compliant |
| Lead-Free | Yes |
PIC18F87K22-I/PT Pin Configuration
| Pin 1 | RG0 — PORTG bit 0 / digital I/O |
| Pin 2 | RG1 — PORTG bit 1 / digital I/O |
| Pin 3 | RG2 — PORTG bit 2 / digital I/O |
| Pin 4 | RG3 — PORTG bit 3 / digital I/O |
| Pin 5 | RG4 — PORTG bit 4 / digital I/O (also RTCC) |
| Pin 6 | VSS — Ground |
| Pin 7 | VDD — Positive supply voltage |
| Pin 8 | RG5 — PORTG bit 5 / digital I/O |
| Pin 9 | RG6 — PORTG bit 6 / digital I/O |
| Pin 10 | RG7 — PORTG bit 7 / digital I/O (also EUSART TX) |
| Pin 11 | VSS — Ground |
| Pin 12 | VDD — Positive supply voltage |
| Pin 13 | RE0 — PORTE bit 0 / digital I/O / AN5 |
| Pin 14 | RE1 — PORTE bit 1 / digital I/O / AN6 |
| Pin 15 | RE2 — PORTE bit 2 / digital I/O / AN7 |
| Pin 16 | RE3 — PORTE bit 3 / digital I/O (also MCLR if configured) |
| Pin 17 | RA0 — PORTA bit 0 / AN0 / analog input |
| Pin 18 | RA1 — PORTA bit 1 / AN1 / analog input |
| Pin 19 | RA2 — PORTA bit 2 / AN2 / analog input |
| Pin 20 | RA3 — PORTA bit 3 / AN3 / analog input |
| Pin 21 | RA4 — PORTA bit 4 / digital I/O |
| Pin 22 | RA5 — PORTA bit 5 / AN4 / digital I/O |
| Pin 23 | RA6 — PORTA bit 6 / oscillator pin |
| Pin 24 | RA7 — PORTA bit 7 / oscillator pin |
| Pin 25 | VSS — Ground |
| Pin 26 | VDD — Positive supply voltage |
| Pin 27 | RB0 — PORTB bit 0 / digital I/O / interrupt-on-change |
| Pin 28 | RB1 — PORTB bit 1 / digital I/O / interrupt-on-change |
| Pin 29 | RB2 — PORTB bit 2 / digital I/O / interrupt-on-change |
| Pin 30 | RB3 — PORTB bit 3 / digital I/O / interrupt-on-change |
| Pin 31 | RB4 — PORTB bit 4 / digital I/O / interrupt-on-change |
| Pin 32 | RB5 — PORTB bit 5 / digital I/O / interrupt-on-change / AN11 |
| Pin 33 | RB6 — PORTB bit 6 / digital I/O / ICSCLK |
| Pin 34 | RB7 — PORTB bit 7 / digital I/O / ICSDAT |
| Pin 35 | VSS — Ground |
| Pin 36 | VDD — Positive supply voltage |
| Pin 37 | RC0 — PORTC bit 0 / digital I/O / AN12 |
| Pin 38 | RC1 — PORTC bit 1 / digital I/O / AN13 |
| Pin 39 | RC2 — PORTC bit 2 / digital I/O / AN14 |
| Pin 40 | RC3 — PORTC bit 3 / digital I/O / AN15 |
| Pin 41 | RC4 — PORTC bit 4 / digital I/O / AN16 |
| Pin 42 | RC5 — PORTC bit 5 / digital I/O / AN17 |
| Pin 43 | RC6 — PORTC bit 6 / digital I/O / AN18 / TX |
| Pin 44 | RC7 — PORTC bit 7 / digital I/O / AN19 / RX |
| Pin 45 | VSS — Ground |
| Pin 46 | VDD — Positive supply voltage |
| Pin 47 | RD0 — PORTD bit 0 / digital I/O |
| Pin 48 | RD1 — PORTD bit 1 / digital I/O |
| Pin 49 | RD2 — PORTD bit 2 / digital I/O |
| Pin 50 | RD3 — PORTD bit 3 / digital I/O |
| Pin 51 | RD4 — PORTD bit 4 / digital I/O |
| Pin 52 | RD5 — PORTD bit 5 / digital I/O |
| Pin 53 | RD6 — PORTD bit 6 / digital I/O |
| Pin 54 | RD7 — PORTD bit 7 / digital I/O |
| Pin 55 | VSS — Ground |
| Pin 56 | VDD — Positive supply voltage |
| Pin 57 | RF0 — PORTF bit 0 / AN5 analog input |
| Pin 58 | RF1 — PORTF bit 1 / AN6 analog input |
| Pin 59 | RF2 — PORTF bit 2 / AN7 analog input |
| Pin 60 | RF3 — PORTF bit 3 / AN8 analog input |
| Pin 61 | RF4 — PORTF bit 4 / AN9 analog input |
| Pin 62 | RF5 — PORTF bit 5 / AN10 analog input |
| Pin 63 | RF6 — PORTF bit 6 / AN11 analog input |
| Pin 64 | RF7 — PORTF bit 7 / AN12 analog input |
| Pin 65 | VSS — Ground |
| Pin 66 | VDD — Positive supply voltage |
| Pin 67 | RH0 — PORTH bit 0 / digital I/O / AN20 |
| Pin 68 | RH1 — PORTH bit 1 / digital I/O / AN21 |
| Pin 69 | RH2 — PORTH bit 2 / digital I/O / AN22 |
| Pin 70 | RH3 — PORTH bit 3 / digital I/O / AN23 |
| Pin 71 | RH4 — PORTH bit 4 / digital I/O |
| Pin 72 | RH5 — PORTH bit 5 / digital I/O |
| Pin 73 | RH6 — PORTH bit 6 / digital I/O |
| Pin 74 | RH7 — PORTH bit 7 / digital I/O |
| Pin 75 | VSS — Ground |
| Pin 76 | VDD — Positive supply voltage |
| Pin 77 | RJ0 — PORTJ bit 0 / digital I/O |
| Pin 78 | RJ1 — PORTJ bit 1 / digital I/O |
| Pin 79 | RJ2 — PORTJ bit 2 / digital I/O |
| Pin 80 | RJ3 — PORTJ bit 3 / digital I/O |
Typical Applications
PIC18F87K22-I/PT is suitable for 6 applications: Capacitive Touch HMI Panels, Battery-Powered Wireless Sensor Nodes, Industrial Control and PLC Modules, USB HID Peripherals and Consumer Devices, Home Automation Controllers, Automotive Body Electronics Sub-Modules.
Capacitive Touch HMI Panels
The PIC18F87K22-I/PT's integrated Charge Time Measurement Unit (CTMU) makes it well-suited for capacitive touch human-machine interface (HMI) panels requiring 8-32 touch keys plus sliders. Its 12-bit ADC with up to 30 channels reads proximity and gesture sensors simultaneously, while the 64 MHz core executes touch-scanning algorithms within tight scan-period budgets. The nanoWatt XLP sleep mode drops current below 100 nA between user interactions, enabling battery-powered remote controls and kitchen appliances. Use the peripheral pin select (PPS) to remap I2C, SPI, and PWM signals without rewiring the PCB. Place 10 nF to 100 nF charge capacitors on CTMU-driven pins to maintain capacitive touch accuracy.
Recommended
Battery-Powered Wireless Sensor Nodes
The PIC18F87K22-I/PT's nanoWatt XLP technology suits always-on sensor nodes powered by coin cells or Li-ion batteries where standby current is the dominant energy drain. Sleep current below 100 nA extends battery life to multiple years in typical duty-cycled applications, while the 64 MHz wake-up core processes sensor data and transmits results via the integrated EUSART or SPI. The wide 1.8 V to 5.5 V supply range allows direct connection to single-cell Li-ion, two AA cells, or regulated 3.3 V rails without boost converters. CTMU provides temperature sensing via time-measurement of an external NTC pair, eliminating a dedicated temperature sensor IC.
Recommended
Industrial Control and PLC Modules
The PIC18F87K22-I/PT's 70 I/O pins and industrial temperature rating make it a strong fit for PLC-style I/O modules, motor-driver interface boards, and factory-automation sub-controllers. The 12-bit ADC with up to 30 channels reads multiple analog sensors (pressure, flow, temperature) simultaneously, while the multiple CCP/ECCP modules generate PWM signals for valve and motor control. SPI and I2C peripherals connect to digital sensors, EEPROM, and display drivers, and the EUSART supports RS-232/RS-485 industrial networks. The robust -40 C to +85 C industrial temperature grade handles factory-floor thermal stress. Use peripheral pin select (PPS) to assign digital functions to spare I/O without board rework.
Recommended
USB HID Peripherals and Consumer Devices
The PIC18F87K22-I/PT integrates a USB 2.0 Full-Speed peripheral with on-chip transceiver, supporting HID-class devices such as keyboards, mice, game controllers, custom input devices, and consumer accessories. The 64 MHz core executes USB stack and host-class handling, while the 4 KB RAM is sufficient for HID report buffers and command parsing. The internal 16 MHz HFINTOSC can be PLL-multiplied to 48 MHz USB-friendly clock without an external crystal, reducing BOM cost. Multiple PWM and CCP modules drive LEDs, RGB lighting, or haptic feedback motors. The nanoWatt XLP sleep mode drops current below 100 nA during USB suspend, meeting USB 2.0 power-conservation requirements.
Recommended
Home Automation Controllers
The PIC18F87K22-I/PT is well-suited to home-automation gateways that aggregate wireless sensor data, drive relays, control LED dimmers, and interface with user touch panels. The 128 KB Flash supports application code plus optional wireless-protocol stacks (Zigbee, LoRa, sub-GHz) running on companion radios over SPI or UART. The CTMU reads capacitive wall-switch touch panels directly, while the ECCP modules generate phase-correct PWM for LED dimming and motor control. The wide 1.8 V to 5.5 V supply range supports both 3.3 V wireless modules and 5 V relay drivers from a single supply rail. nanoWatt XLP enables battery-backed RTC operation during grid power loss.
Recommended
Automotive Body Electronics Sub-Modules
The PIC18F87K22-E/PT (extended temperature grade of the same die) supports body-electronics sub-modules such as HVAC control heads, seat controllers, mirror adjusters, and ambient-lighting drivers where -40 C to +125 C operation is required. The PIC18F87K22-I/PT itself is suitable for cabin-temperature sub-modules at -40 C to +85 C. Multiple CCP/ECCP channels drive PWM-controlled actuators, while the 12-bit ADC reads position sensors and thermistors with automotive-grade precision. CAN bus is not integrated, so external CAN transceivers (such as MCP2551) handle in-vehicle networking. The wide 5 V supply tolerance handles 12 V automotive rail transients when paired with proper TVS protection.
Recommended
Recommended Products Summary
Engineering reference data for PIC18F87K22-I/PT — comparison, design guidance, and compliance information.
Selection Guide
Comparison with Alternatives
| Parameter | This Product | PIC18F87K22-E/PT | PIC18F87K22T-I/PT | PIC18F86K22-I/PT | PIC18F8722-I/PT | PIC18F87J94-I/PT |
|---|---|---|---|---|---|---|
| Package | 80-pin TQFP (PT), 12x12 mm | 80-pin TQFP (PT), 12x12 mm - same | 80-pin TQFP (PT), 12x12 mm - same | 80-pin TQFP (PT), 12x12 mm - same | 80-pin TQFP (PT), 12x12 mm - same | 80-pin TQFP (PT), 12x12 mm - same |
| Brand | Microchip Technology | Microchip Technology | Microchip Technology | Microchip Technology | Microchip Technology | Microchip Technology |
| Flash Program Memory | 128 KB (64K x 16) | 128 KB (64K x 16) - same | 128 KB (64K x 16) - same | 64 KB - 50% | 128 KB (64K x 16) - same | 128 KB (64K x 16) - same |
| Data RAM | 4 KB | 4 KB - same | 4 KB - same | 4 KB - same | 3.9 KB - similar | 4 KB - same |
| Maximum CPU Frequency | 64 MHz | 64 MHz - same | 64 MHz - same | 64 MHz - same | 40 MHz - 37.5% lower | 64 MHz - same |
| nanoWatt XLP Technology | Yes (<100 nA sleep) | Yes - same | Yes - same | Yes - same | No - legacy | Yes - same |
| CTMU (Capacitive Touch) | Yes | Yes - same | Yes - same | Yes - same | No - legacy | Yes - same |
| Operating Temperature | -40 C to +85 C (industrial) | -40 C to +125 C (extended) | -40 C to +85 C - same | -40 C to +85 C - same | -40 C to +85 C - same | -40 C to +85 C - same |
| Approximate Unit Price (qty 1) | $8.42 | $9.10 - higher (ext. temp) | $8.42 - same (tape reel) | $7.30 - lower (less Flash) | $8.95 - similar | $7.95 - similar |
Key Differentiators
- Higher temperature range option without redesign (vs PIC18F87K22-I/PT)
- 50% more Flash than 86K22 sibling (vs PIC18F86K22-I/PT)
- Adds nanoWatt XLP, CTMU, and PPS over legacy F8722 (vs PIC18F8722-I/PT)
Design Notes
The PIC18F87K22-I/PT supports a wide supply range from 1.8 V to 5.5 V, with full 64 MHz operation specified from 4.2 V to 5.5 V. For 3.3 V systems, use the HFINTOSC with PLL enabled but consider lowering CPU frequency via software if 64 MHz is not required. Decouple each VDD/VSS pair with a 100 nF ceramic capacitor placed within 5 mm of the corresponding pins; add a 10 uF bulk capacitor near the device. For battery applications using sleep mode, ensure no source impedance on VDD exceeds 10 ohm to allow proper nanoWatt XLP wake-up.
When migrating from PIC18F8722 to PIC18F87K22, verify analog channel assignments because some ANx pins map differently between the two families. The K22 family adds peripheral pin select (PPS), which requires explicit configuration in firmware; ports do not default to specific peripheral functions. MCLR must be pulled high through a 10 kohm resistor and a 100 nF capacitor to ground for proper reset operation. Use ICD 3 or PICkit 4 for in-circuit debugging; older ICD 2 units may require firmware updates to support K22 configuration bits.
The 80-pin TQFP package at 12x12 mm with 0.5 mm pitch requires 4-layer PCB design with continuous ground plane under the device for thermal dissipation and EMI suppression. Place decoupling capacitors on each VDD/VSS pair within 5 mm trace length, and route crystal traces (if used) with short, symmetric paths to GND. Expose the central TQFP thermal pad (if present) or use a top-side copper pour under the device to dissipate up to 1 W continuous power. Keep high-speed signals (SPI, EUSART) trace lengths matched within 25 mm to avoid timing skew.
The USB 2.0 Full-Speed peripheral requires a 48 MHz USB clock derived from the 16 MHz HFINTOSC via PLL; verify the USB clock accuracy is within +/- 0.25% to meet USB spec. Add a 100 nF bypass capacitor directly on the USB D+/D- lines near the connector, and route D+/D- as a 90-ohm differential pair with controlled impedance. For capacitive touch applications using CTMU, place 10-100 nF charge capacitors close to the CTMU pin and route touch-pad traces with minimum 0.5 mm clearance from digital signals to prevent capacitive coupling.
Compliance Information
RoHS and lead-free compliant. -I industrial grade (-40 C to +85 C) is not AEC-Q100 qualified; for AEC-Q100 automotive applications, use PIC18F87K22-E/PT (extended grade, -40 C to +125 C) or dedicated automotive PIC18 variants. REACH compliance confirmed via Microchip regulatory documentation.