PIC16F877-20I/PT - 8-Bit 20MHz 14KB Flash MCU 44-TQFP | Microchip
MPN: PIC16F877-20I/PT β Active| Qty | Unit Price | Extended |
|---|---|---|
| 1 | $7.95 | $7.95 |
| 10 | $7.16 | $71.60 |
| 100 | $6.36 | $636.00 |
| 500 | $5.71 | $2,855.00 |
| 1,000 | $5.1 | $5,100.00 |
PIC16F877-20I/PT Overview
An 8-bit microcontroller (MCU) is a single-chip computer with an 8-bit data path, ALU, program counter, RAM, ROM/FLASH, and integrated peripherals. The PIC architecture is a RISC design with only 35 single-word instructions, making it beginner-friendly and deterministic for real-time control. Microcontrollers in the PIC16 family sit in the broader taxonomy: 8-bit MCU -> microcontroller -> embedded controller -> semiconductor IC, and are widely used in industrial, automotive (premium-line), consumer, and educational applications.
Key features include 20 MHz operation from 2.0 V to 5.5 V, an integrated ICD (In-Circuit Debugger) interface, self-programming support, brown-out reset (BOR), power-on reset (POR), watchdog timer (WDT), and an industrial temperature grade (-40C to +85C) denoted by the "I" suffix. The "-20" speed suffix specifies 20 MHz operation versus the 4 MHz / 10 MHz variants in the same family.
The PIC16F877 implements a Harvard architecture with separate program and data buses, 14-bit instruction width, and a hardware multiplier is not present, but single-cycle ALU ops deliver predictable timing. The device is upward code-compatible with PIC16C5X, PIC12CXXX, and PIC16C7X, simplifying migration from older designs.
Typical applications include industrial control systems, sensor interfacing, motor control (low-power), HVAC thermostats, security panels, instrumentation, and educational/development boards. The wide 2.0-5.5 V range simplifies battery and line-powered designs alike.
When designing, ensure adequate decoupling (0.1 uF + 10 uF bulk) close to VDD/AVDD/VSS pins and respect the 5.5 V absolute maximum on any pin to avoid latch-up. For new designs, Microchip recommends migrating to PIC16F887 or PIC16F877A for enhanced features and active lifecycle status.
This page synthesizes distributor pricing, drop-in alternatives, and practical design notes not found in the manufacturer datasheet alone.
Drop-in alternatives for PIC16F877-20I/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 PIC16F877-20I/PT (same form factor and footprint) β differing in Package, Operating Temperature, Core Architecture, Timers, ADC.
Quick Comparison Tool β Select alternative parts for side-by-side comparison:
PIC16F877A-20I/PT
β Drop-Inπ Reference alternative (not in catalog)
PIC16F887-I/PT
β Drop-Inβ In Stock
$1.66 / Unit
View Datasheet βPIC16F874-20I/PT
β Drop-Inπ Reference alternative (not in catalog)
PIC16F877-20I/P
β Drop-Inβ In Stock
$5.1 / Unit
View Datasheet βPIC16F877-20I/L
β Drop-Inβ In Stock
$9.05 / Unit
View Datasheet βPIC16F877-20/PT
β Drop-Inπ Reference alternative (not in catalog)
PIC16F877-20I/PT Maximum Ratings & Electrical Characteristics
| Core Processor | PIC |
| Core Size | 8-Bit |
| Maximum Clock Frequency | 20 MHz |
| Instruction Cycle Time | 200 ns |
| Program Memory Size | 14 KB (8K x 14) FLASH |
| RAM Size | 368 bytes |
| EEPROM Size | 256 bytes |
| Number of I/O Pins | 33 |
| A/D Converter | 8 channels x 10-bit |
| Timers | Timer0, Timer1, Timer2 |
| CCP Modules | 2 (Capture/Compare/PWM) |
| Connectivity | I2C, SPI, UART/USART |
| Supply Voltage | 2.0 V to 5.5 V |
| Operating Temperature | -40C to +85C (Industrial) |
| Package | 44-TQFP (10x10 mm) |
| Mounting Type | Surface Mount |
| MSL Level | 3 |
| RoHS Status | Compliant |
PIC16F877-20I/PT Pin Configuration
| Pin 1 | MCLR/VPP β Master Clear (Reset) input / Programming voltage |
| Pin 2 | RA0/AN0 β PORTA bit 0 / Analog input 0 |
| Pin 3 | RA1/AN1 β PORTA bit 1 / Analog input 1 |
| Pin 4 | RA2/AN2 β PORTA bit 2 / Analog input 2 |
| Pin 5 | RA3/AN3/VREF+ β PORTA bit 3 / Analog input 3 / ADC VREF+ |
| Pin 6 | RA4/AN4/TOCKI β PORTA bit 4 / Analog input 4 / Timer0 clock |
| Pin 7 | RA5/AN5/SS β PORTA bit 5 / Analog input 5 / SPI Slave Select |
| Pin 8 | RE0/RD/AN6 β PORTE bit 0 / Read control for Parallel Slave Port / Analog input 6 |
| Pin 9 | RE1/WR/AN7 β PORTE bit 1 / Write control for PSP / Analog input 7 |
| Pin 10 | RE2/CS/AN8 β PORTE bit 2 / Chip Select for PSP |
| Pin 11 | VDD β Positive supply (+2.0V to +5.5V) |
| Pin 12 | VSS β Ground reference |
| Pin 13 | OSC1/CLKI β Oscillator crystal input / External clock |
| Pin 14 | OSC2/CLKO β Oscillator crystal output / Clock output |
| Pin 15 | RC0/T1OSO/T1CKI β PORTC bit 0 / Timer1 oscillator output / Timer1 clock |
| Pin 16 | RC1/T1OSI/CCP2 β PORTC bit 1 / Timer1 oscillator input / CCP2 |
| Pin 17 | RC2/CCP1 β PORTC bit 2 / CCP1 PWM output |
| Pin 18 | RC3/SCK/SCL β PORTC bit 3 / SPI clock / I2C clock |
| Pin 19 | RD0/PSP0 β PORTD bit 0 / Parallel Slave Port bit 0 |
| Pin 20 | RD1/PSP1 β PORTD bit 1 / Parallel Slave Port bit 1 |
| Pin 21 | RD2/PSP2 β PORTD bit 2 / Parallel Slave Port bit 2 |
| Pin 22 | RD3/PSP3 β PORTD bit 3 / Parallel Slave Port bit 3 |
| Pin 23 | RC4/SDI/SDA β PORTC bit 4 / SPI data in / I2C data |
| Pin 24 | RC5/SDO β PORTC bit 5 / SPI data out |
| Pin 25 | RC6/TX/CK β PORTC bit 6 / USART transmit / USART clock |
| Pin 26 | RC7/RX/DT β PORTC bit 7 / USART receive / USART data |
| Pin 27 | RD4/PSP4 β PORTD bit 4 / Parallel Slave Port bit 4 |
| Pin 28 | RD5/PSP5 β PORTD bit 5 / Parallel Slave Port bit 5 |
| Pin 29 | RD6/PSP6 β PORTD bit 6 / Parallel Slave Port bit 6 |
| Pin 30 | RD7/PSP7 β PORTD bit 7 / Parallel Slave Port bit 7 |
| Pin 31 | VSS β Ground reference |
| Pin 32 | VDD β Positive supply (+2.0V to +5.5V) |
| Pin 33 | RB0/INT β PORTB bit 0 / External interrupt |
| Pin 34 | RB1 β PORTB bit 1 |
| Pin 35 | RB2 β PORTB bit 2 |
| Pin 36 | RB3/PGM β PORTB bit 3 / Low-voltage ICSP programming |
| Pin 37 | RB4 β PORTB bit 4 (interrupt-on-change) |
| Pin 38 | RB5 β PORTB bit 5 (interrupt-on-change) |
| Pin 39 | RB6/PGC β PORTB bit 6 / ICSP clock |
| Pin 40 | RB7/PGD β PORTB bit 7 / ICSP data |
| Pin 41 | VSS β Ground reference |
| Pin 42 | VDD β Positive supply (+2.0V to +5.5V) |
| Pin 43 | NC β Not connected (per datasheet) |
| Pin 44 | NC β Not connected (per datasheet) |
Typical Applications
PIC16F877-20I/PT is suitable for 7 applications: Industrial Control Systems, HVAC Thermostat Control, Security and Alarm Panels, Educational Microcontroller Boards, Sensor Data Acquisition Systems, Small Motor Control (DC, Stepper), Consumer Electronics Control Boards.
Industrial Control Systems
The PIC16F877-20I/PT is well-suited for industrial control due to its 14 KB FLASH, 33 I/O pins, 8-channel 10-bit ADC, and industrial -40C to +85C temperature grade. In PLC-style applications, the device can scan multiple sensors, drive relays through its I/O, and communicate via RS-485/USART. The PIC RISC architecture executes instructions in 200 ns at 20 MHz, providing deterministic control loops suitable for real-time monitoring. The integrated EEPROM (256 bytes) stores calibration data and configuration parameters that survive power cycles. Compared to discrete logic, this single-chip solution reduces BOM cost and PCB area.
Recommended
HVAC Thermostat Control
The PIC16F877-20I/PT integrates the analog sensing, PWM actuator control, and user-interface I/O needed for HVAC thermostat designs in a single 44-TQFP package. Its 8-channel 10-bit ADC handles multiple temperature sensors (NTC thermistors or IC sensors like MCP9700), while its 2 CCP modules generate PWM signals to control fan speeds and valve actuators. The wide 2.0-5.5 V supply range allows direct operation from rectified 24 VAC HVAC line power with simple regulation. The 200 ns instruction cycle provides tight PID control loop timing, while 14 KB FLASH accommodates user-interface state machines and scheduling algorithms.
Recommended
Security and Alarm Panels
Security alarm panels benefit from the PIC16F877-20I/PT's combination of 33 I/O pins for zone monitoring, integrated EEPROM for storing event logs, and serial connectivity for central-station reporting. The device can scan dozens of wired zones via matrix keypad scanning, drive sirens via PWM, and communicate over PSTN or GSM modules via USART. Brown-out reset (BOR) and watchdog timer (WDT) ensure reliable operation during power glitches common in security installations. The 14 KB FLASH stores the panel operating system plus custom zone logic, while 368 bytes RAM handles real-time event buffering.
Recommended
Educational Microcontroller Boards
Universities and training centers use the PIC16F877-20I/PT in development boards because of its 35-instruction RISC architecture that beginners can master quickly. The 44-TQFP package exposes all 33 I/O pins on standard 0.1-inch header spacing through breakout boards, allowing students to wire LEDs, switches, sensors, and displays. ICD (In-Circuit Debugger) support means real-time breakpoint debugging is built-in without extra hardware. The combination of 14 KB FLASH, ADC, PWM, and serial peripherals makes it suitable for teaching ADC sampling, PWM motor control, I2C sensor interfacing, and UART communication in one platform.
Recommended
Sensor Data Acquisition Systems
Multi-sensor data loggers benefit from the PIC16F877-20I/PT's 8-channel 10-bit ADC and 256-byte EEPROM for storing calibration constants. In environmental monitoring stations, the device can sample temperature, humidity, pressure, and gas sensors, time-stamp readings via software RTC, and store data to external EEPROM or SD cards via SPI. The 20 MHz CPU provides fast ADC conversion rates for high-speed sampling, while low-power sleep modes (with WDT wake-up) extend battery life in remote deployments. The wide 2.0-5.5 V supply range supports both 3.3 V sensor modules and 5 V legacy interfaces.
Recommended
Small Motor Control (DC, Stepper)
The PIC16F877-20I/PT drives small DC and stepper motors through its 2 CCP (Capture/Compare/PWM) modules and general-purpose I/O, providing closed-loop speed or position control without external motor controllers. The 20 MHz CPU computes PID control loops in microseconds, while PWM frequencies up to 20 kHz avoid audible motor whine. Direction control via GPIO, current sensing via the ADC, and fault detection via interrupts create a complete single-chip motor controller in a 44-TQFP package. Industrial temperature grade and 5.5 V tolerance suit factory automation environments.
Recommended
Consumer Electronics Control Boards
Consumer appliances (washing machines, dishwashers, microwave ovens, coffee machines) use the PIC16F877-20I/PT as a cost-effective system controller with sufficient I/O for user keypads, displays, and actuators. The 14 KB FLASH accommodates state machines for multi-mode operation, while 256 bytes EEPROM stores user preferences through power cycles. The integrated USART supports WiFi/Bluetooth module integration for smart-appliance variants. Industrial temperature tolerance suits under-cabinet and garage installations where temperatures vary widely.
Recommended
Recommended Products Summary
Engineering reference data for PIC16F877-20I/PT β comparison, design guidance, and compliance information.
Selection Guide
Comparison with Alternatives
| Parameter | This Product | PIC16F877A-20I/PT | PIC16F887-I/PT | PIC16F874-20I/PT |
|---|---|---|---|---|
| Brand | Microchip Technology | Microchip Technology | Microchip Technology | Microchip Technology |
| Package | 44-TQFP (10x10 mm) | 44-TQFP - same | 44-TQFP - same | 44-TQFP - same |
| Program Memory | 14 KB FLASH | 14 KB FLASH | 14 KB FLASH | 12 KB FLASH |
| RAM Size | 368 bytes | 368 bytes | 368 bytes | 192 bytes |
| EEPROM Size | 256 bytes | 256 bytes | 256 bytes | 256 bytes |
| Number of I/O | 33 | 33 | 36 | 33 |
| Clock Frequency | 20 MHz | 20 MHz | 20 MHz | 20 MHz |
| ADC | 8ch x 10-bit | 8ch x 10-bit (enhanced) | 14ch x 10-bit (enhanced) | 8ch x 10-bit |
| Temperature Grade | -40C to +85C (Industrial) | -40C to +85C (Industrial) | -40C to +85C (Industrial) | -40C to +85C (Industrial) |
| Lifecycle Status | Active (legacy recommended) | Active (recommended) | Active (preferred for new designs) | Active (legacy) |
Key Differentiators
- Industrial temperature grade as standard (vs PIC16F877-20/PT)
- Identical silicon with surface-mount TQFP package (vs PIC16F877-20I/P (PDIP-40))
- Legacy compatibility with active production (vs PIC16F877A-20I/PT)
- More memory than PIC16F874 sibling (vs PIC16F874-20I/PT)
Design Notes
Decoupling: Place a 0.1 uF ceramic capacitor as close as possible to each VDD pin (11, 32, 42) and a single 10 uF tantalum or electrolytic bulk capacitor near the supply entry point. The PIC16F877 has multiple VDD/VSS pairs to reduce digital switching noise coupling into analog sections. For ADC accuracy, also decouple AVDD (when used) separately from DVDD. Estimated: switching transients on digital I/O can inject noise into the ADC if decoupling is inadequate; a poor layout can degrade ADC SNR by 1-2 LSBs.
Crystal/oscillator layout: Keep the crystal (or ceramic resonator) within 1 cm of OSC1 (pin 13) and OSC2 (pin 14), with a ground guard ring around the oscillator traces to prevent digital switching noise from coupling into the clock. Use short, equal-length traces from each crystal pin to the corresponding OSC pin. For high-speed or noisy designs, consider a 4-pin crystal oscillator module with its own ground and VDD pins instead of a discrete crystal.
MCLR pin: Pin 1 (MCLR/VPP) must NEVER be left floating. Use a 10 kohm pull-up to VDD and a 100 nF capacitor to ground for typical reset circuits. The MCLR pin is also the programming voltage entry; floating or incorrectly biased MCLR can cause erratic operation or programming failure. For ICSP (In-Circuit Serial Programming), add an ESD protection diode and series resistor on MCLR. Also note that configuration bits (FOSC, WDTE, etc.) must be set correctly in code via __CONFIG directives or the device may not run after reset.
ADC input design: For accurate 10-bit ADC conversions, add a small RC filter (typically 100 ohm + 100 nF) on each analog input to filter switching noise from adjacent digital pins. The ADC sample-and-hold requires the source impedance to be below 2.5 kohm for full accuracy; if using higher-impedance sensors, add a unity-gain buffer (e.g., MCP6001 op-amp) between the sensor and the ADC pin. Acquisition time must be programmed appropriately based on source impedance.
Compliance Information
RoHS compliant per Microchip product page. Lead-free (Pb-free) TQFP package. Not AEC-Q100 qualified - for automotive designs requiring AEC-Q100, consider PIC16F877A-I/PT automotive variants. Microchip is QS-9000 compliant at its fabrication facilities.