PIC16F877T-04E/PT - 8-bit 4MHz 14KB Flash MCU 44-TQFP | Microchip
MPN: PIC16F877T-04E/PT ✓ Active| Qty | Unit Price | Extended |
|---|---|---|
| 1 | $9.5 | $9.50 |
| 10 | $8.55 | $85.50 |
| 100 | $7.6 | $760.00 |
| 500 | $6.85 | $3,425.00 |
| 1,000 | $6.1 | $6,100.00 |
PIC16F877T-04E/PT Overview
What is an 8-bit microcontroller? An 8-bit MCU (microcontroller) is a single-chip computer that integrates a CPU, non-volatile program memory (Flash/ROM), volatile working memory (RAM), EEPROM, and a fixed set of peripherals (timers, ADC, USART, I2C/SPI, GPIO) on one die. The PIC16F877 sits in the mid-range PIC taxonomy (PIC10/12/14/16/18/24/32), positioned between baseline PIC12/16 and enhanced PIC18 cores. With its Harvard RISC architecture, 35 single-word instructions, and 14-bit instruction word, the PIC16F877 family delivers deterministic timing suitable for direct register-level control loops.
Key features of the PIC16F877T-04E/PT include 8 channels of 10-bit analog-to-digital conversion (ADC), three timers (Timer0, Timer1, Timer2), a USART with synchronous/asynchronous modes, a Master Synchronous Serial Port (MSSP) supporting SPI and I2C (both Master and Slave), a capture/compare/PWM (CCP) module, and up to 33 digital I/O pins across five ports (PORTA through PORTE). The device supports in-circuit serial programming (ICSP) via two dedicated pins, enabling bootloader-free field firmware updates.
The PIC16F877 architecture uses a 14-bit instruction word with a two-stage pipeline, a hardware multiplier (8x8), and a programmable code-protection scheme. Brown-out reset (BOR), power-on reset (POR), and a watchdog timer (WDT) with its own on-chip RC oscillator protect against code runaway and brown-out events. The Flash program memory supports 100,000 erase/write cycles typical and >40-year endurance, making the part suitable for long-life industrial equipment.
Typical applications for the PIC16F877T-04E/PT include industrial automation controllers, sensor signal conditioning, motor control (low-side PWM), HVAC thermostats, smart metering, educational development boards, and legacy upgrade designs. The 'E' suffix denotes the Extended (industrial) temperature grade, and 'T' indicates Tape and Reel packaging, while the 'PT' suffix specifies the 44-pin TQFP (10x10 mm) form factor.
When designing with this part, ensure that your linker file reserves the top of Flash for the ICSP/DEBUG vector (0x1F00 area on this family) and that your in-circuit programmer is configured for mid-range PIC16F parts, not PIC18F. Designers migrating to newer alternatives should consider the PIC16F887, which Microchip lists as a newer device with enhanced peripherals.
This page synthesizes distributor pricing, drop-in alternatives within the same 44-pin TQFP footprint, and practical design notes not found in the manufacturer datasheet alone.
Drop-in alternatives for PIC16F877T-04E/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 PIC16F877T-04E/PT (same form factor and footprint) — differing in Package, Timers, Core Architecture, Operating Temperature, ADC.
Quick Comparison Tool — Select alternative parts for side-by-side comparison:
PIC16F877-04E/PT
✅ Drop-In✓ In Stock
$3.25 / Unit
View Datasheet →PIC16F877-04I/PT
✅ Drop-In📋 Reference alternative (not in catalog)
PIC16F877T-04E/PQ
✅ Drop-In✓ In Stock
$8.75 / Unit
View Datasheet →PIC16F877T-04E/L
✅ Drop-In✓ In Stock
$7.45 / Unit
View Datasheet →PIC16F877A-E/PT
✅ Drop-In✓ In Stock
$7.8 / Unit
View Datasheet →PIC16F877AT-I/PTG
✅ Drop-In✓ In Stock
$6.2 / Unit
View Datasheet →PIC16F877T-04E/PT Maximum Ratings & Electrical Characteristics
| Series | PIC 16F |
| Core Processor | PIC |
| Core Size | 8-bit |
| Architecture | RISC, Harvard |
| Instruction Set | 35 single-word instructions |
| Instruction Word Width | 14-bit |
| Max CPU Speed | 4 MHz |
| Instruction Cycle Time | 200 ns |
| Program Memory (Flash) | 14 KB (8K x 14 words) |
| EEPROM Data Memory | 256 bytes |
| RAM Data Memory | 368 bytes |
| Operating Voltage (VDD) | 5 V (4.0 V to 5.5 V range typical for F-series) |
| I/O Pins | 33 (PORTA-PORTE) |
| ADC | 8 channels x 10-bit |
| Timers | 3 (Timer0, Timer1, Timer2) |
| Serial Interfaces | USART + MSSP (SPI/I2C) |
| PWM/CCP Modules | 1 x CCP |
| Package | 44-pin TQFP (10x10 mm), 'PT' suffix |
| Operating Temperature | -40 C to +125 C (Extended, 'E' suffix) |
| Mounting Type | Surface Mount |
| ICSP Programming | Yes (In-Circuit Serial Programming) |
| Flash Endurance | 100,000 erase/write cycles typical |
| RoHS Status | Compliant |
PIC16F877T-04E/PT Pin Configuration
| Pin 1 | MCLR/VPP — Master Clear (reset) input / programming voltage input |
| Pin 2 | RA0/AN0 — PORTA bit 0 / Analog input 0 |
| Pin 3 | RA1/AN1 — PORTA bit 1 / Analog input 1 |
| Pin 4 | RA2/AN2/VREF- — PORTA bit 2 / Analog input 2 / ADC negative reference |
| Pin 5 | RA3/AN3/VREF+ — PORTA bit 3 / Analog input 3 / ADC positive reference |
| Pin 6 | RA4/T0CKI — PORTA bit 4 / Timer0 clock input |
| Pin 7 | RA5/AN4/SS — PORTA bit 5 / Analog input 4 / SPI Slave Select |
| Pin 8 | RE0/RD/AN5 — PORTE bit 0 / Parallel port read control / Analog input 5 |
| Pin 9 | RE1/WR/AN6 — PORTE bit 1 / Parallel port write control / Analog input 6 |
| Pin 10 | RE2/CS/AN7 — PORTE bit 2 / Parallel port chip select / Analog input 7 |
| Pin 11 | VDD — Positive supply (5V) |
| Pin 12 | VSS — Ground reference |
| Pin 13 | OSC1/CLKI — Oscillator input / external clock input |
| Pin 14 | OSC2/CLKO — Oscillator output / clock output |
| Pin 15 | RC0/T1OSO/T1CKI — PORTC bit 0 / Timer1 oscillator output / Timer1 clock input |
| Pin 16 | RC1/T1OSI/CCP2 — PORTC bit 1 / Timer1 oscillator input / CCP2 output |
| 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 TX / USART clock |
| Pin 26 | RC7/RX/DT — PORTC bit 7 / USART RX / 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 (5V) |
| Pin 33 | RB0/INT — PORTB bit 0 / External interrupt input |
| Pin 34 | RB1 — PORTB bit 1 |
| Pin 35 | RB2 — PORTB bit 2 |
| Pin 36 | RB3/PGM — PORTB bit 3 / Low-voltage ICSP programming input |
| Pin 37 | RB4 — PORTB bit 4 |
| Pin 38 | RB5 — PORTB bit 5 |
| Pin 39 | RB6/PGC — PORTB bit 6 / ICSP clock (programming/debug) |
| Pin 40 | RB7/PGD — PORTB bit 7 / ICSP data (programming/debug) |
| Pin 41 | NC — Not connected (per datasheet package drawing) |
| Pin 42 | NC — Not connected (per datasheet package drawing) |
| Pin 43 | NC — Not connected (per datasheet package drawing) |
| Pin 44 | NC — Not connected (per datasheet package drawing) |
Typical Applications
PIC16F877T-04E/PT is suitable for 7 applications: Industrial Automation Controller, Sensor Signal Conditioning & Data Logging, Stepper and DC Motor Control (Low-Side PWM), HVAC Thermostat and Building Automation, Smart Energy Metering & Utility Monitoring, Educational Development Board & Training Platform, Consumer Appliance Control Board.
Industrial Automation Controller
The PIC16F877T-04E/PT is widely deployed as an industrial automation I/O controller, driving relays, contactors, and opto-isolated 24V inputs through its 33 GPIO across PORTA-PORTE. Its Extended -40 C to +125 C temperature rating covers factory floor and outdoor cabinet environments without derating. The on-chip 8-channel 10-bit ADC reads 4-20 mA loop transmitters or 0-10 V sensor outputs with adequate resolution for process monitoring, while the 35-instruction RISC core deterministically services a 1-2 ms control loop. Compared with discrete logic designs, the F877 collapses a board's worth of glue logic into one IC, simplifying BOM and EMI.
Recommended
Sensor Signal Conditioning & Data Logging
The PIC16F877T-04E/PT is a strong fit for multi-channel sensor signal conditioning nodes because its 8-channel 10-bit ADC multiplexes thermocouple, RTD bridge, or load-cell amplifiers without an external analog MUX. The 256-byte EEPROM stores per-channel calibration coefficients that survive power cycles, while 368 bytes of SRAM buffer scan tables. A real-time clock (DS1307) on the I2C MSSP bus timestamps samples; the USART forwards them to a host PC or PLC. The Extended temperature range suits outdoor weather stations and refrigerated monitoring. For higher-resolution designs, migrate to PIC16F887 (14 ADC channels).
Recommended
Stepper and DC Motor Control (Low-Side PWM)
The PIC16F877T-04E/PT drives small unipolar stepper motors and brushed DC motors through its CCP PWM module and PORTB/PORTC outputs, switching external MOSFET half-bridges at up to ~20 kHz PWM. The 200 ns instruction cycle (at 4 MHz) lets the firmware sample current-sense ADCs and adjust duty cycle within each PWM period, implementing a closed-loop torque controller. Watchdog timer and brown-out reset protect against code runaway and supply dips, which are common in motor-driver environments with inductive kickback. For multi-axis CNC or servo control, migrate to PIC18F or dsPIC33.
Recommended
HVAC Thermostat and Building Automation
The PIC16F877T-04E/PT runs low-power HVAC thermostat firmware with the F877's on-chip ADC reading thermistor temperature, the USART linking to a wall-mounted network, and the MSSP I2C bus driving a 16-segment LCD or character LCD. The CCP module generates the call-for-heat PWM signal sent to a furnace relay or 24 VAC valve. Brown-out reset and watchdog timer guard against the noisy 24 VAC environment typical of HVAC control boards. PIC16F877A variants with EEPROM-backed user schedules are commonly deployed for setpoint programming.
Recommended
Smart Energy Metering & Utility Monitoring
The PIC16F877T-04E/PT serves as the metering MCU in single-phase smart electricity meters, using the on-chip 10-bit ADC to sample a current-transformer-derived waveform at 1-2 kHz and compute RMS power. The MSSP SPI bus feeds results to an external ADE7753 energy-measurement IC for accuracy, while EEPROM records kWh totals. The 256-byte on-chip EEPROM plus external 24LC series EEPROM logs tamper and time-of-use data. Watchdog timer prevents meter lockup after brownouts. For revenue-grade metering, migrate to PIC18F46K22 with 12-bit ADC and higher MIPS.
Recommended
Educational Development Board & Training Platform
The PIC16F877T-04E/PT is the canonical microcontroller for university embedded systems and vocational training because of its 44-pin TQFP breakout, ample Flash/RAM/EEPROM, and full peripheral set (ADC, timers, USART, SPI, I2C, PWM) that students can exercise in a single lab session. The 35-instruction RISC core fits a single lecture on assembly programming, and ICSP allows firmware updates without removing the chip from the breadboard. Textbooks such as Mazidi's 'PIC Microcontroller and Embedded Systems' use the F877 as the reference target. Universities can prototype on F877 dev boards and migrate to PIC16F887 for production.
Recommended
Consumer Appliance Control Board
The PIC16F877T-04E/PT appears in washing machines, dishwashers, microwave ovens, and small kitchen appliances where its 33 GPIO can drive seven-segment LED displays, keypad matrices, buzzer, and triac-fired heater or motor relays. The 14 KB Flash stores appliance cycle profiles and fault logs, while the 256-byte EEPROM retains user preferences through power cycles. The CCP PWM drives the universal motor speed control, and the MSSP I2C bus connects to a peripheral temperature or humidity sensor. AEC-Q100 is NOT qualified on F877, so automotive-class appliances require PIC16F877A-I/PT or migration to PIC18F family.
Recommended
Recommended Products Summary
Engineering reference data for PIC16F877T-04E/PT — comparison, design guidance, and compliance information.
Selection Guide
Comparison with Alternatives
| Parameter | This Product | PIC16F877-04E/PT | PIC16F877-04I/PT | PIC16F877T-04E/PQ | PIC16F877T-04E/L | PIC16F877A-E/PT | PIC16F877AT-I/PTG |
|---|---|---|---|---|---|---|---|
| Package | 44-TQFP (10x10 mm), PT suffix | 44-TQFP (10x10 mm) - same | 44-TQFP (10x10 mm) - same | 44-MQFP (10x10 mm) - same body, gull-wing | 44-PLCC - socket-mount, different land pattern | 44-TQFP (10x10 mm) - same | 44-TQFP (10x10 mm) - same |
| Brand | Microchip Technology | Microchip Technology | Microchip Technology | Microchip Technology | Microchip Technology | Microchip Technology | Microchip Technology |
| Flash Memory | 14 KB (8K x 14) | 14 KB | 14 KB | 14 KB | 14 KB | 14 KB | 14 KB |
| Max Clock Speed | 4 MHz | 4 MHz | 4 MHz | 4 MHz | 4 MHz | 20 MHz | 20 MHz |
| Temperature Grade | Extended -40 C to +125 C | Extended -40 C to +125 C | Industrial -40 C to +85 C | Extended -40 C to +125 C | Extended -40 C to +125 C | Extended -40 C to +125 C | Industrial -40 C to +85 C |
| Packaging Form | Tape & Reel | Tray | Tray | Tape & Reel | Tape & Reel | Tube | Tape & Reel |
| EEPROM | 256 bytes | 256 bytes | 256 bytes | 256 bytes | 256 bytes | 256 bytes | 256 bytes |
| ADC Channels | 8 x 10-bit | 8 x 10-bit | 8 x 10-bit | 8 x 10-bit | 8 x 10-bit | 8 x 10-bit | 8 x 10-bit |
| Param Match vs This Part | 100% (baseline) | 100% | 90% | 90% | 80% | 95% | 90% |
Key Differentiators
- Extended -40 C to +125 C temperature grade over Industrial-grade siblings (vs PIC16F877-04I/PT)
- 20 MHz-capable core in A-revision for higher-throughput firmware (vs PIC16F877A-E/PT)
- Microchip-recommended newer substitute available (vs PIC16F887-I/PT)
Design Notes
Place a 100 nF decoupling capacitor as close as possible to each VDD pin (pins 11 and 32 on the 44-TQFP), plus a single 10 uF bulk capacitor near the device. The PIC16F877 has two VDD pins for noise immunity; both must be decoupled. For noisy industrial environments, add a ferrite bead in series with VDD and a 10 uF tantalum bulk cap. Brown-out reset (BOR) is enabled by the configuration fuses - leave it enabled to recover cleanly from supply dips in motor-control and metering circuits. VPP (pin 1) must have a 10 k pull-up to VDD if low-voltage ICSP is not used.
Keep the 4 MHz crystal or resonator within 1 cm of pins 13-14 (OSC1/OSC2) and surround it with a ground guard ring to reduce EMI. Avoid routing PORTA analog traces across digital lines; the ADC on PORTA shares the bus with the digital I/O. Use the dedicated VREF+/VREF- pins (RA3/RA2) when ADC accuracy matters, and add a 10 nF cap on each reference pin. Place a 100 nF cap on the MCLR/VPP pin and never leave it floating during normal operation. For TQFP layout, fan out the 0.8 mm pitch pins to vias in the inner power plane.
Do not configure both the ICSP PGC/PGD (RB6/RB7) and the on-chip debug module on RB6/RB7 without planning for the resulting loss of those pins for general GPIO. Configuration word _DEBUG (W3:1) = 0 disables the debugger but frees RB6/RB7; _DEBUG = 1 keeps the debugger but RB6/RB7 are not general-purpose. When using the MSSP I2C mode, remember to set the SSPEN bit, configure the SCL release rate via the SSPADD register for the desired bus speed (100 kHz or 400 kHz), and add 4.7 k to 10 k pull-ups on SDA/SCL. The ADC requires the ADCON1 register to be set for analog mode (PCFG bits) before reading channels - forgetting this leaves pins stuck in digital mode.
When driving long cables (e.g., RS-485 to sensor) from the USART pins (RC6/RC7), add a series 100 ohm resistor and a 10 k pull-down to limit ringing. For SPI bus runs above 10 cm, lower the SCK rate and add 100 ohm source terminators. The MSSP I2C bus must never exceed 400 pF total capacitance - on long buses, add a bus extender such as MCP4725 or P82B715. The CCP1 PWM frequency is set by Timer2 - for 8-bit resolution at 10 kHz with 4 MHz FOSC, set PR2=99 and the prescaler to 1.
Compliance Information
RoHS compliant per Microchip product page and DigiKey listing. PIC16F877 family is not AEC-Q100 qualified; for automotive applications use PIC16F877A-I/PT Q1 variants or migrate to PIC18F family.