PIC16F631-E/SO - 8-bit PIC MCU, 1.75KB Flash, 20MHz, 20-SOIC | Microchip
MPN: PIC16F631-E/SO ✓ Active| Qty | Unit Price | Extended |
|---|---|---|
| 1 | $1.4038 | $1.40 |
| 10 | $1.25 | $12.50 |
| 100 | $1.1 | $110.00 |
| 500 | $0.95 | $475.00 |
| 1,000 | $0.5927 | $592.70 |
PIC16F631-E/SO Overview
An 8-bit microcontroller (MCU) is a single-chip computer built around an 8-bit data path, a small program memory, RAM, integrated peripherals (timers, ADC, comparators, communications), and a CPU core that executes one instruction per instruction cycle (or per 4 clocks in PIC mid-range architecture). PIC microcontrollers occupy the 8-bit MCU hypernym in the broader semiconductor taxonomy: MCU -> microcontroller -> embedded controller -> semiconductor IC. They are widely used where deterministic real-time response, low cost, and low power are more important than raw throughput. The PIC16F631 belongs to the low-pin-count (14-/20-pin) sub-family of the PIC16 mid-range architecture and integrates nanoWatt power management for sleep-mode currents below 1 µA.
Key features include 11 I/O pins with individual direction control, an 8-bit Timer0/Timer2 plus a 16-bit Timer1, two analog comparators with programmable reference, an enhanced universal synchronous/asynchronous receiver-transmitter (EUSART) for RS-232/RS-485 links, an I2C/SPI master/slave MSSP peripheral, a 10-bit ADC with up to 11 input channels, an enhanced PWM module with up to 4 outputs, and an internal 8 MHz oscillator calibrated to ±1% across voltage and temperature. The -E (Extended) temperature grade supports -40 °C to +125 °C operation, suitable for industrial and automotive underhood environments.
The architecture is a Harvard RISC core with 35 single-word instructions, separate program and data buses, a hardware stack of 8 levels, and interrupt capability with automatic context saving. NanoWatt technology provides multiple idle/sleep modes (SLEEP, IDLE, and a low-power Timer1 oscillator mode) that allow average current draw well below 100 µA in duty-cycled battery applications. On-chip in-circuit serial programming (ICSP) and in-circuit debugger (ICD) interfaces enable field re-programming and real-time emulation without removing the part from the board.
Typical applications include consumer appliance control, small motor drivers, LED lighting controllers, battery chargers, security keypads and PIR-sensor panels, HVAC damper/valve actuators, automotive interior lighting and accessory modules, and low-cost industrial sensor nodes. The combination of EUSART + MSSP + ADC + PWM in a 20-pin footprint is a sweet spot for replacing multiple discrete timers or glue logic.
When designing with this part, budget the ICSP/ICD pins (RB6/RB7 on the 20-pin DIP/SOIC) for in-system programming access - either through dedicated header pads or test-points - because they are not usable as general-purpose I/O once the device is locked, and the oscillator configuration bits selected at Flash programming time determine the clock source for the entire application lifetime.
This page synthesizes distributor pricing, drop-in alternatives from Microchip's PIC16 low-pin-count family, and practical design notes not found in the manufacturer datasheet.
Drop-in alternatives for PIC16F631-E/SO — 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 PIC16F631-E/SO (same form factor and footprint) — differing in ADC, Package, Timers, Operating Temperature, I/O Pins.
Quick Comparison Tool — Select alternative parts for side-by-side comparison:
PIC16F631-I/SO
✅ Drop-In✓ In Stock
$1.28 / Unit
View Datasheet →PIC16F630-I/SO
✅ Drop-In📋 Reference alternative (not in catalog)
PIC16F677-I/P
✅ Drop-In📋 Reference alternative (not in catalog)
PIC16F685-I/SO
✅ Drop-In✓ In Stock
$1.68 / Unit
View Datasheet →PIC16F690-I/SO
✅ Drop-In✓ In Stock
$1.62 / Unit
View Datasheet →PIC16F631-E/SO Maximum Ratings & Electrical Characteristics
| Device Family | PIC16F (mid-range 8-bit) |
| Program Memory Type | Flash |
| Program Memory Size | 1.75 KB (1792 words x 14-bit) |
| Data EEPROM | 128 bytes |
| Data SRAM | 64 bytes |
| Maximum CPU Clock | 20 MHz |
| Supply Voltage Range | 4.5 V to 5.5 V (PIC16F631 -E operating range) |
| I/O Pins | 11 |
| Timers | 1 x 8-bit Timer0, 1 x 16-bit Timer1, 1 x 8-bit Timer2 |
| ADC | 10-bit, up to 11 channels |
| Comparators | 2 analog comparators |
| Communication Peripherals | EUSART + MSSP (I2C/SPI) |
| PWM Channels | Enhanced CCP, up to 4 PWM outputs |
| Operating Temperature | -40 °C to +125 °C (Extended -E grade) |
| Package | 20-pin SOIC (SO), 7.50 mm body width, tube |
| Mounting Type | Surface Mount |
| ICSP/ICD Pins | RB6/ICSPCLK, RB7/ICSPDAT |
| Instruction Set | 35 single-word instructions, Harvard RISC |
| RoHS Status | Compliant |
| Lead-Free | Yes (Pb-free SOIC package) |
PIC16F631-E/SO Pin Configuration
| Pin 1 | RA0/AN0/C1IN+/ICSPDAT — PORTA bit 0 / Analog input 0 / Comparator 1 non-inverting input / ICSP data |
| Pin 2 | RA1/AN1/C1IN-/VREF — PORTA bit 1 / Analog input 1 / Comparator 1 inverting input / external VREF |
| Pin 3 | RA2/AN2/C1OUT — PORTA bit 2 / Analog input 2 / Comparator 1 output |
| Pin 4 | RA3/AN3/C1IN+/MCLR/VPP — PORTA bit 3 / Analog input 3 / Comparator 1 input / Master Clear (Reset) input / ICSP VPP |
| Pin 5 | RA4/AN4/T0CKI/C2OUT — PORTA bit 4 / Analog input 4 / Timer0 clock input / Comparator 2 output (open-drain) |
| Pin 6 | RA5/AN5/C2IN+/SS/HLVDIN — PORTA bit 5 / Analog input 5 / Comparator 2 non-inverting input / SPI Slave Select / High-Low Voltage Detect input |
| Pin 7 | VSS — Ground reference |
| Pin 8 | OSC1/CLKIN — Crystal/Resonator input or external clock input |
| Pin 9 | OSC2/CLKOUT — Crystal/Resonator output or 1/4 CPU clock output |
| Pin 10 | RC0/T1OSO/T1CKI — PORTC bit 0 / Timer1 oscillator output / Timer1 clock input |
| Pin 11 | RC1/T1OSI/CCP2 — PORTC bit 1 / Timer1 oscillator input / Capture-Compare-PWM 2 |
| Pin 12 | RC2/CCP1 — PORTC bit 2 / Capture-Compare-PWM 1 output |
| Pin 13 | RC3/SCK/SCL — PORTC bit 3 / SPI clock / I2C clock |
| Pin 14 | RC4/SDI/SDA — PORTC bit 4 / SPI data in / I2C data |
| Pin 15 | RC5/SDO — PORTC bit 5 / SPI data out |
| Pin 16 | RC6/TX/CK — PORTC bit 6 / EUSART TX / EUSART clock |
| Pin 17 | RC7/RX/DT — PORTC bit 7 / EUSART RX / EUSART data |
| Pin 18 | RB4/AN10 — PORTB bit 4 / Analog input 10 |
| Pin 19 | RB5/AN11 — PORTB bit 5 / Analog input 11 |
| Pin 20 | VDD — Positive supply voltage |
Typical Applications
PIC16F631-E/SO is suitable for 7 applications: Consumer Appliance Control, LED Lighting Controllers, Automotive Interior Modules, Battery-Powered Sensor Nodes, Industrial Sensor Signal Conditioning, Small Motor and Solenoid Drivers, Security Keypads and PIR Panels.
Consumer Appliance Control
The PIC16F631-E/SO fits mid-complexity white-goods and small-appliance controllers thanks to its 1.75 KB Flash, integrated 10-bit ADC for temperature/sense inputs, and an enhanced PWM module for triac or FET-driven heater/motor stages. Its -40 °C to +125 °C extended temperature grade handles underhood appliances and oven-control boards where Industrial-grade MCUs would fail. The EUSART and MSSP give a ready path to a user-interface keypads, segment-LCD drivers, or a BLE/Zigbee daughter module via UART. With 11 I/O pins and nanoWatt sleep modes, the part can run for years on a single coin cell in intermittently-powered sensor panels.
Recommended
LED Lighting Controllers
The PIC16F631-E/SO is widely used in constant-current LED drivers and architectural RGBW lighting nodes. Its enhanced PWM module provides up to 4 channels with programmable dead-band, supporting direct drive of high-side MOSFETs through a gate driver, while the two analog comparators implement cycle-by-cycle current limiting without CPU intervention. The 10-bit ADC samples the current-sense amplifier for closed-loop brightness control. At 20 MHz instruction throughput the MCU has ample headroom to run DMX-512, DALI, or 0-10 V dimming protocols concurrently, and the nanoWatt sleep current below 1 µA is critical for always-on standby power budgets mandated by energy regulations.
Recommended
Automotive Interior Modules
The PIC16F631-E/SO is AEC-Q100-aware and qualified to Microchip's Extended -40 °C to +125 °C grade, making it a common choice for non-safety automotive interior loads such as ambient lighting, dome-light controllers, seat-heater switches, and accessory-driven HVAC flap actuators. The integrated EUSART links to a body-control module via LIN or K-Line, while the MSSP drives a SPI-controlled LED driver or a small character display. With hardware PWM and 11 I/O, the MCU can drive multiple LEDs, read rotary encoders for climate knobs, and monitor a thermistor for over-temperature shutdown without external logic.
Recommended
Battery-Powered Sensor Nodes
For wireless remote sensors, alarm contacts, and utility-meter endpoints, the PIC16F631-E/SO delivers the right balance of low cost, low power, and integrated peripherals. NanoWatt technology with SLEEP current below 1 µA combined with the Timer1 real-time-clock oscillator allows the part to wake periodically, take an ADC or comparator reading, transmit over a sub-GHz radio via EUSART/SPI, and return to deep sleep. The 2.0 V minimum VDD supports direct operation from two AA alkaline cells down to end-of-life voltage. Internal EEPROM rated for >1M write cycles provides reliable non-volatile storage of calibration coefficients and event logs.
Recommended
Industrial Sensor Signal Conditioning
The PIC16F631-E/SO integrates the analog front-end, digital control, and communication interfaces needed for low-cost industrial sensor transmitters. The two analog comparators with programmable voltage reference can implement window comparators, threshold detection, and zero-crossing detection without burdening the CPU. The 10-bit ADC samples bridge sensors, RTDs, or 4-20 mA loop signals, while the EUSART outputs a UART, RS-485, or LIN frame. Its 4.5 V to 5.5 V supply range is compatible with 5 V industrial backplanes, and the -E temperature grade handles factory-floor enclosures without derating.
Recommended
Small Motor and Solenoid Drivers
The PIC16F631-E/SO is a good fit for brushed DC motor, small stepper, and solenoid control in vending machines, access-control locks, and printer paper-feed assemblies. The enhanced PWM with complementary outputs and programmable dead-band can directly switch a half-H bridge driver such as the MCP1755/MCP1755S, while the 16-bit Timer1 handles tachometer feedback from a Hall sensor or optical encoder. Comparators provide hardware over-current protection that bypasses firmware latency, and the MSSP drives an SPI-position sensor or an external DAC for current-loop control. The 20-pin SOIC keeps the PCB small enough for embedded actuator assemblies.
Recommended
Security Keypads and PIR Panels
The PIC16F631-E/SO powers compact security keypads, PIR motion panels, and glass-break detector boards. Its 11 I/O drive a 4x4 matrix keypad with software debounce, while the analog comparator with internal reference acts as the window discriminator for the PIR element bias, eliminating an external op-amp. The EUSART streams event logs to a central panel or to a wireless transceiver. NanoWatt sleep with <1 µA current extends battery life in wireless PIR devices to multiple years, and the 128-byte EEPROM stores configuration, tamper counts, and installer settings without external NVRAM.
Recommended
Recommended Products Summary
Engineering reference data for PIC16F631-E/SO — comparison, design guidance, and compliance information.
Selection Guide
Comparison with Alternatives
| Parameter | This Product | PIC16F631-I/SO | PIC16F630-I/SO | PIC16F677-I/P | PIC16F685-I/SO | PIC16F690-I/SO |
|---|---|---|---|---|---|---|
| Brand | Microchip Technology | Microchip Technology | Microchip Technology | Microchip Technology | Microchip Technology | Microchip Technology |
| Package | 20-SOIC (7.50 mm) | 20-SOIC (7.50 mm) - same | 20-SOIC (7.50 mm) - same | 20-SOIC (7.50 mm) - same | 20-SOIC (7.50 mm) - same | 20-SOIC (7.50 mm) - same |
| Flash Program Memory | 1.75 KB | 1.75 KB | 1.75 KB | 3.5 KB | 7 KB | 7 KB |
| SRAM / EEPROM | 64 B / 128 B | 64 B / 128 B | 64 B / 128 B | 128 B / 256 B | 256 B / 256 B | 256 B / 256 B |
| I/O Pins | 11 | 11 | 11 | 17 | 17 | 18 |
| Temperature Grade | Extended -40 to +125 °C | Industrial -40 to +85 °C | Industrial -40 to +85 °C | Industrial -40 to +85 °C | Industrial -40 to +85 °C | Industrial -40 to +85 °C |
| MSSP (I2C/SPI) | Yes | Yes | No | Yes | Yes | Yes |
| Comparators | 2 | 2 | 1 | 2 | 2 | 2 |
| ADC Channels / Resolution | 11 / 10-bit | 11 / 10-bit | 5 / 10-bit | 14 / 10-bit | 12 / 10-bit | 12 / 10-bit |
| Unit Price (1000 pcs) | $0.59 | $0.55 | $0.48 | $1.20 | $1.35 | $1.45 |
Key Differentiators
- Extended -40 °C to +125 °C temperature grade (vs PIC16F631-I/SO)
- Integrated MSSP (I2C/SPI) peripheral (vs PIC16F630-I/SO)
- Two analog comparators with programmable reference (vs PIC16F630-I/SO)
- Cost-optimized 11 I/O footprint with full PIC16 mid-range feature set (vs PIC16F690-I/SO)
Design Notes
The PIC16F631-E/SO supports two primary supply configurations: full-performance mode (4.5 V to 5.5 V) at 20 MHz, and low-voltage mode (2.0 V to 5.5 V) at reduced clock. Brown-out Reset (BOR) is enabled by CONFIG2 and should be left on in production to prevent code runaway during battery droop or supply collapse. The MCU has no internal voltage regulator - it is a direct 5 V core, so add a 100 nF decoupling cap as close as possible to VDD (pin 20) and a 10 µF bulk cap on the board's 5 V rail. For battery designs, choose an LDO like MCP1700 (1.6 µA quiescent) to preserve nanoWatt sleep performance.
Estimated: the PIC16F631-E/SO in the 20-SOIC package dissipates approximately 25 mW at 20 MHz / 5 V active load (typical IDD ~5 mA at 20 MHz from datasheet). Junction temperature rise is negligible (<2 °C) under normal operation. In extended-temperature applications at +125 °C ambient, ensure that the MCU remains within its 150 °C absolute maximum junction rating. The wide-body SOIC's exposed lead frame provides better thermal coupling than narrow-body SOIC; no explicit heatsinking is required for typical digital logic duty cycles.
Three common pitfalls: (1) Forgetting that MCLR (pin 4) is also the ICSP VPP - tie it through a 10 kΩ pull-up to VDD with a 100 nF cap to ground, never leave it floating; (2) Using the internal 8 MHz oscillator as the system clock without enabling the PLL - the F631 has no PLL, so the maximum CPU clock is 20 MHz regardless of HFINTOSC setting; (3) Assuming the analog comparator output can drive LEDs directly - C1OUT/C2OUT on RA2/RA4 share digital I/O functionality and should not source more than 25 mA. Always read the CONFIG1/CONFIG2 fuse settings before programming; an erroneous MCLR disable will brick the device.
Place the ICSP header or test pads on RB6/ICSPCLK (pin 18) and RB7/ICSPDAT (pin 19) accessible from the board edge - once code-protected, these pins can no longer be used for in-circuit debugging without erasing the device. Keep the 20 MHz crystal or resonator within 5 mm of OSC1/OSC2 (pins 8-9) and surround it with a ground pour to reduce EMI injection into nearby analog inputs. If using HFINTOSC, the layout constraint is relaxed but accuracy is factory-calibrated to ±1% only across the full temperature range - calibrate the internal oscillator in firmware for tighter timing requirements.
Compliance Information
RoHS compliant and lead-free matte-tin finish per Microchip product page. Not formally AEC-Q100 qualified - the -E temperature grade supports automotive underhood use but AEC-Q100 PPAP documentation is not provided. REACH compliant per Microchip substance declaration.