PIC16F628-04E/SO - 8-bit 4MHz Flash MCU, 3.5KB, 18-SOIC | Microchip
MPN: PIC16F628-04E/SO ✗ پایان تولیدPIC16F628-04E/SO نمای کلی
A microcontroller (MCU) is a single-chip computer containing a CPU core, program and data memory, programmable I/O peripherals, and supporting analog or communication blocks. The PIC16F628 sits inside the broader PIC16 mid-range family, which in turn belongs to the 8-bit microcontroller category that includes competitors such as the Atmel AVR ATtiny series and the 8051 family; these MCUs occupy the entry-level tier of the embedded system hierarchy (MCU -> microcontroller -> embedded processor -> semiconductor IC).
Key features include an internal 4MHz RC oscillator with calibration, programmable brown-out detect (BOD), a watchdog timer (WDT) with its own on-chip RC oscillator for reliable operation, power-on reset (POR), power-up timer (PWRT) and oscillator start-up timer (OST), an analog comparator module with programmable on-chip voltage reference and programmable input multiplexing, programmable weak pull-ups on PORTB, in-circuit serial programming (ICSP), and low-voltage programming support. The 'E' suffix denotes an extended automotive temperature grade of -40C to +125C.
The PIC16F628 uses Microchip's enhanced mid-range 8-bit RISC architecture with only 35 single-word instructions, allowing most instructions to execute in a single instruction cycle (200 ns at 20 MHz, 1 us at 4 MHz). Its Harvard architecture separates program and data buses, and the device supports both internal and external oscillator modes plus software-selectable low-speed clock operation.
Typical applications include automotive body and chassis electronics, appliance controls, industrial sensor interfaces, low-end remote controls, and hobbyist/educational projects that benefit from the PIC's mature toolchain (MPLAB X IDE, XC8 compiler, PICkit programmers). The internal RC oscillator and on-chip EEPROM simplify BOM by eliminating external timing and non-volatile storage parts.
When designing with this device, note that the 'E' temperature grade makes it suitable for -40C to +125C environments but the '04' speed grade limits operation to 4 MHz; for 20 MHz designs choose the PIC16F628-20/SO. Always reserve the MCLR pin or use the internal MCLR configuration, and follow Microchip AN529 for migration paths to PIC16F628A or PIC16F18444 if extended peripherals or longer product life are required.
This page synthesizes distributor pricing, drop-in same-package alternatives, and practical design notes that go beyond a raw restatement of the manufacturer datasheet, helping engineers select, source, and qualify the PIC16F628-04E/SO for production.
جایگزینهای drop-in برای PIC16F628-04E/SO — همان پکیج، سازگار پینبهپین. قطعات با پکیج متفاوت که نیاز به تغییر PCB دارند مستثنی هستند.
گونهها در این سری
مدلهای همسری که جایگزین مستقیم هستند برای PIC16F628-04E/SO (همان فرمفاکتور و فوتپرینت) — متفاوت در Package, Operating Temperature, Analog Comparators, MSL Level, Internal Oscillator.
PIC16F628-04/SO
✅ جایگزین مستقیمبرای قیمت تماس بگیرید
مشاهده دیتاشیت ←PIC16F628-04I/SO
✅ جایگزین مستقیمبرای قیمت تماس بگیرید
مشاهده دیتاشیت ←PIC16F628-20/SO
✅ جایگزین مستقیم📋 جایگزین مرجع (خارج از کاتالوگ)
PIC16F628A-I/SO
✅ جایگزین مستقیمبرای قیمت تماس بگیرید
مشاهده دیتاشیت ←PIC16F628A-E/SO
✅ جایگزین مستقیم📋 جایگزین مرجع (خارج از کاتالوگ)
PIC16F627-04I/SO
✅ جایگزین مستقیمبرای قیمت تماس بگیرید
مشاهده دیتاشیت ←PIC16F628-04E/SO حداکثر مقادیر مجاز و مشخصات الکتریکی
| Core Architecture | PIC 8-bit RISC (mid-range enhanced) |
| Program Memory | 3.5 KB Flash (2K x 14 words) |
| RAM | 224 bytes |
| EEPROM Data Memory | 128 bytes |
| Maximum Clock Speed | 4 MHz (200 ns instruction cycle) |
| Instruction Set | 35 single-word instructions, mostly single-cycle |
| I/O Pins | 16 |
| Supply Voltage (VDD) | 4.5 V to 5.5 V |
| دمای کاری | -40C to +125C (automotive / 'E' grade) |
| بستهبندی | 18-pin SOIC (SO) |
| نوع نصب | Surface Mount |
| Internal Oscillator | Yes, 4 MHz RC (calibrated) |
| Watchdog Timer | Yes, with dedicated on-chip RC oscillator |
| Brown-Out Detect (BOD) | Programmable |
| Analog Comparators | 2 with programmable on-chip VREF module |
| Programming Interface | ICSP (In-Circuit Serial Programming), low-voltage programming supported |
| سطح MSL | 1 (unlimited floor life at <=30C / 85% RH) |
| Lead-Free / RoHS | Lead-free finish, RoHS compliant |
پیکربندی پین PIC16F628-04E/SO
| پین 1 | RA2/AN2/VREF — Bidirectional I/O / analog channel 2 / VREF output |
| پین 2 | RA3/AN3/CMP1 — Bidirectional I/O / analog channel 3 / comparator-1 output |
| پین 3 | RA4/AN4/T0CKI — Bidirectional I/O / analog channel 4 / Timer0 clock input (open-drain) |
| پین 4 | MCLR/VPP — Master Clear reset input (active low) / programming voltage input |
| پین 5 | VSS — Ground reference |
| پین 6 | RB0/INT — Bidirectional I/O / external interrupt input |
| پین 7 | RB1/RX/DT — Bidirectional I/O / USART RX / data in async mode |
| پین 8 | RB2/TX/CK — Bidirectional I/O / USART TX / clock in sync mode |
| پین 9 | RB3/CCP1 — Bidirectional I/O / Capture/Compare/PWM channel 1 |
| پین 10 | RB4/PGM — Bidirectional I/O / low-voltage programming input |
| پین 11 | RB5 — Bidirectional I/O |
| پین 12 | RB6/T1OSC1/PGC — Bidirectional I/O / Timer1 oscillator input / ICSP clock |
| پین 13 | RB7/T1OSC2/PGD — Bidirectional I/O / Timer1 oscillator output / ICSP data |
| پین 14 | VDD — Positive supply voltage (4.5 V to 5.5 V) |
| پین 15 | OSC1/CLKI — Crystal oscillator input / external clock input |
| پین 16 | OSC2/CLKO — Crystal oscillator output / clock output (Fosc/4) |
| پین 17 | RA0/AN0 — Bidirectional I/O / analog channel 0 |
| پین 18 | RA1/AN1 — Bidirectional I/O / analog channel 1 |
کاربردهای معمول
PIC16F628-04E/SO مناسب است برای 6 کاربردs: Automotive Body and Chassis Electronics, Appliance Control Boards, Industrial Sensor Interface Nodes, Remote Control and Consumer IR Transmitters, Educational and Hobbyist Development Boards, Security and Access Control Panels.
Automotive Body and Chassis Electronics
The PIC16F628-04E/SO's extended -40C to +125C automotive temperature grade and internal 4 MHz RC oscillator make it a strong fit for body controllers, lighting modules, and sensor interfaces in vehicles. With 16 high-current I/O capable of directly driving LEDs and relays, the device eliminates external driver transistors in many lamp-control circuits, while the on-chip EEPROM provides 128 bytes of non-volatile storage for trim, calibration, or fault logs. Its 4 MHz instruction execution at 1 us per instruction is sufficient for body-control polling rates in the 1-10 ms range. The 18-SOIC package fits standard automotive PCB land patterns and survives typical under-hood thermal stress.
پیشنهادی
Appliance Control Boards
White-goods appliances (washers, dishwashers, refrigerators) commonly use 8-bit PIC MCUs in the PIC16F family, and the PIC16F628-04E/SO brings 3.5 KB of flash and 16 I/O to front-panel and motor-control boards. The internal oscillator removes the cost of an external crystal, while the two on-chip analog comparators with programmable VREF support direct interfacing with NTC temperature sensors and over-current shunt amplifiers without an external op-amp. Watchdog timer and brown-out detect protect against the brown-out and ESD events typical of motor-drive environments, and the 18-SOIC footprint remains compatible with hand-soldered rework and high-volume lead-free reflow profiles.
پیشنهادی
Industrial Sensor Interface Nodes
Distributed industrial sensor nodes need an inexpensive, deterministic MCU that can wake on analog change and poll several digital inputs - exactly the workload for which the PIC16F628-04E/SO was designed. The PIC16F628's 35-instruction RISC core delivers 200 ns deterministic response time at 20 MHz and 1 us at 4 MHz, ideal for time-multiplexed sensor polling. Its 16 I/O drive LEDs, opto-isolated inputs, and relay coils directly via the high-current sink/source capability, while the 224-byte RAM is sufficient for buffering 4-8 sensor samples before transmitting. The wide VDD tolerance (4.5-5.5 V) allows direct connection to industrial 5 V rails without additional regulation.
پیشنهادی
Remote Control and Consumer IR Transmitters
Battery-powered handheld remote controls benefit from the PIC16F628-04E/SO's low sleep current, small 18-SOIC footprint, and 3.5 KB flash that comfortably fits IR protocol stacks (RC5, NEC, SIRC) plus manufacturer IDs. The internal 4 MHz oscillator eliminates the external resonator that would otherwise take board space and add cost, while the on-chip analog comparator can be reused for battery-voltage monitoring via a resistor divider. The 128-byte EEPROM is enough to store paired-device codes, and ICSP allows firmware updates through the existing IR LED test pads without disassembly.
پیشنهادی
Educational and Hobbyist Development Boards
The PIC16F family, especially the PIC16F628-04E/SO, remains a popular teaching platform because its 35-instruction RISC architecture is learnable in a single lab session and its free toolchain (MPLAB X IDE + XC8 compiler + PICkit 5 debugger) supports the entire family. The 18-SOIC variant has a standard 0.1 inch-compatible breakout footprint when socketed, and the internal 4 MHz oscillator removes the timing-section lab exercise. Students can experiment with the on-chip comparator, EEPROM emulation, and PORTB weak pull-ups without external components, and the automotive temperature grade survives accidental soldering mishaps without damage.
پیشنهادی
Security and Access Control Panels
Alarm panels, RFID readers, and electronic-lock controllers benefit from the PIC16F628-04E/SO's combination of EEPROM storage for access codes, watchdog timer for tamper resilience, and analog comparators for signal-level detection on wired sensor loops. The 16 I/O can directly multiplex a 4x4 keypad matrix and drive a piezo buzzer, while the on-chip VREF module provides a stable threshold for the analog comparator without external precision parts. Its small 18-SOIC footprint fits behind a wall keypad, and ICSP allows field firmware updates via a 5-pin header that doubles as the programming test point in production.
پیشنهادی
خلاصه محصولات پیشنهادی
دادههای مرجع مهندسی برای PIC16F628-04E/SO — مقایسه، راهنمای طراحی و اطلاعات انطباق.
راهنمای انتخاب
مقایسه با جایگزینها
| پارامتر | این محصول | PIC16F628-04/SO | PIC16F628-04I/SO | PIC16F628-20/SO | PIC16F628A-I/SO | PIC16F628A-E/SO | PIC16F627-04I/SO |
|---|---|---|---|---|---|---|---|
| Brand | Microchip Technology | Microchip Technology | Microchip Technology | Microchip Technology | Microchip Technology | Microchip Technology | Microchip Technology |
| Package | 18-SOIC (SO) | 18-SOIC (SO) - same | 18-SOIC (SO) - same | 18-SOIC (SO) - same | 18-SOIC (SO) - same | 18-SOIC (SO) - same | 18-SOIC (SO) - same |
| Max Clock Speed | 4 MHz | 4 MHz | 4 MHz | 20 MHz | 20 MHz | 20 MHz | 4 MHz |
| Program Memory | 3.5 KB Flash | 3.5 KB Flash | 3.5 KB Flash | 3.5 KB Flash | 3.5 KB Flash | 3.5 KB Flash | 1.75 KB Flash |
| RAM | 224 bytes | 224 bytes | 224 bytes | 224 bytes | 224 bytes | 224 bytes | 224 bytes |
| Operating Temperature | -40C to +125C | 0C to +70C | -40C to +85C | -40C to +85C | -40C to +85C | -40C to +125C | -40C to +85C |
| Supply Voltage (VDD) | 4.5 V to 5.5 V | 4.5 V to 5.5 V | 4.5 V to 5.5 V | 4.5 V to 5.5 V | 4.5 V to 5.5 V | 4.5 V to 5.5 V | 4.5 V to 5.5 V |
| I/O Pins | 16 | 16 | 16 | 16 | 16 | 16 | 16 |
| Lifecycle Status | NRND | NRND | NRND | NRND | Active | Active | NRND |
تفاوتهای کلیدی
- Automotive -40C to +125C temperature grade (در مقابلPIC16F628-04I/SO)
- Lowest-cost automotive PIC16 option (در مقابلPIC16F628A-E/SO)
- Full 3.5 KB program memory (در مقابلPIC16F627-04I/SO)
- Calibrated internal RC oscillator (در مقابلPIC16F628-04E/P (PDIP variant))
یادداشتهای طراحی
The PIC16F628-04E/SO operates from a single 4.5 V to 5.5 V supply on VDD (pin 14) with VSS (pin 5) as ground. Place a 100 nF decoupling capacitor as close as possible to the VDD pin with a short trace to VSS, and add a 10 uF bulk capacitor at the board's supply entry. In noisy motor or relay environments, add a ferrite bead in series with VDD to suppress conducted noise; the on-chip POR, PWRT, and OST circuits require only that VDD rise monotonically and stay above 4.5 V within 72 ms for a clean reset.
When using an external crystal on pins 15 (OSC1) and 16 (OSC2), keep the traces short, symmetric, and surrounded by a ground pour to minimize stray capacitance. If the design uses the internal 4 MHz RC oscillator, leave OSC1/OSC2 as standard I/O (RA7/RB0 in some configurations) or float them with traces short to avoid coupling noise into the internal oscillator. Always provide a robust MCLR circuit - either a 10 kohm pull-up to VDD plus a 100 nF to ground for noise immunity, or use the internal MCLR configuration (CONFIG_MCLRE_OFF) to free the pin as RA3 input only.
Estimated: do not assume the '04' speed grade can be overclocked to 20 MHz - it is a tested spec at 4 MHz and timing violations above that are not characterized. Always set the configuration bits (FOSC, WDTE, PWRTE, BODEN, LVP) explicitly in source code; relying on factory defaults can leave LVP enabled and pin RB4 reserved for programming, blocking its use as general I/O. Finally, when migrating PIC16F628 firmware to PIC16F628A silicon, review Microchip migration document DS30292 because a few SFR addresses and interrupt vectors moved.
The PIC16F628-04E/SO's PORTB weak pull-ups (programmable individually) are typically rated at 50-400 uA - sufficient for switch debouncing but not for high-speed signal biasing. For analog comparator inputs (C1IN+/C1IN-), add a small RC filter (10 kohm + 100 pF) to reject RF interference above the comparator bandwidth. The USART pins (RB1/RB2) require their TRIS bits cleared for output or set for input; misconfigured TRIS is the most common cause of 'dead UART' symptoms on this device.
اطلاعات انطباق
RoHS compliant lead-free finish per Microchip product page. AEC-Q100 is a third-party automotive qualification; PIC16F628-04E/SO has an 'E' temperature grade (-40C to +125C) but Microchip does not separately certify this part to AEC-Q100 - it is 'automotive temperature grade' rather than 'automotive qualified'. Verify AEC-Q100 status separately for safety-critical automotive designs.