PIC16HV540-04I/P - 8-Bit 4MHz OTP MCU w/ HV Reset | Microchip
MPN: PIC16HV540-04I/P ✓ Active| Qty | Unit Price | Extended |
|---|---|---|
| 1 | $3.1 | $3.10 |
| 10 | $2.78 | $27.80 |
| 100 | $2.45 | $245.00 |
| 500 | $2.12 | $1,060.00 |
| 1,000 | $1.85 | $1,850.00 |
PIC16HV540-04I/P Overview
A microcontroller (MCU) is a single-chip computer that integrates a CPU, memory, and programmable I/O peripherals. The PIC16HV540 belongs to the RISC (Reduced Instruction Set Computer) subfamily of 8-bit microcontrollers, sitting beneath the broader category of embedded controllers and above general-purpose microprocessors in the computing hierarchy. Its 12-bit-wide instruction word and 33 single-word instruction set yield approximately 2:1 code compression versus competing 8-bit CISC architectures, simplifying firmware development.
Key features of this -04I/P variant include a 4 MHz maximum clock, an on-chip shunt voltage regulator that allows direct operation from 5 V to 12 V supplies without an external regulator, a watchdog timer (WDT), power-on reset (POR), and brown-out detect (BOD). The /P suffix indicates a plastic PDIP-18 package; the -04 speed grade limits the oscillator to 4 MHz; the I suffix marks the industrial temperature grade. The integrated HV reset eliminates the need for an external reset supervisor, reducing BOM count in cost-sensitive designs.
Typical applications include low-cost battery chargers, smoke detectors, LED controllers, simple sensor interfaces, and replacement of discrete logic in appliances and toys. The wide supply range (3.5 V to 15 V with internal regulator) suits unregulated or battery-fed systems. Designers should ensure OTP programming is performed before final PCB assembly because OTP parts cannot be re-programmed in-circuit once sealed.
Drop-in alternatives for PIC16HV540-04I/P — 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 PIC16HV540-04I/P (same form factor and footprint) — differing in Package, Program Memory Size, Program Memory Type, Core Architecture, Mounting Type.
Quick Comparison Tool — Select alternative parts for side-by-side comparison:
PIC16HV540-04/P
✅ Drop-In📋 Reference alternative (not in catalog)
PIC16HV540/JW
✅ Drop-In✓ In Stock
$6.9 / Unit
View Datasheet →PIC16HV540-04I/SO
✅ Drop-In✓ In Stock
$1.78 / Unit
View Datasheet →PIC16HV540-04/P301
✅ Drop-In📋 Reference alternative (not in catalog)
PIC16C54C-04/P
✅ Drop-In✓ In Stock
$1.71 / Unit
View Datasheet →PIC16C54A-04/P
✅ Drop-In✓ In Stock
$3.75 / Unit
View Datasheet →PIC16HV540-04I/P Maximum Ratings & Electrical Characteristics
| Core | PIC16 (8-bit RISC) |
| Maximum Clock Frequency | 4 MHz |
| Instruction Execution Time | 200 ns |
| Program Memory Type | OTP (One-Time Programmable) |
| Program Memory Size | 768 bytes (512 x 12) |
| Data RAM | 25 bytes |
| I/O Pins | 12 |
| Number of Instructions | 33 single-word |
| Instruction Width | 12 bits |
| Package | PDIP-18 (through-hole) |
| Operating Voltage | 3.5 V to 15 V (with on-chip HV regulator) |
| Operating Temperature | -40C to +85C (industrial) |
| Speed Grade | -04 (4 MHz) |
| On-chip Voltage Regulator | Yes (high-voltage shunt regulator) |
| Watchdog Timer | Yes |
| Brown-out Detect (BOD) | Yes |
| Power-on Reset (POR) | Yes |
PIC16HV540-04I/P Pin Configuration
| Pin 1 | RA2 — Bidirectional I/O port A bit 2 |
| Pin 2 | RA3 — Bidirectional I/O port A bit 3 |
| Pin 3 | RA4/T0CKI — Bidirectional I/O port A bit 4 / Timer0 clock input |
| Pin 4 | MCLR — Master clear reset input |
| Pin 5 | VSS — Ground reference |
| Pin 6 | RB0/INT — Bidirectional I/O port B bit 0 / External interrupt |
| Pin 7 | RB1 — Bidirectional I/O port B bit 1 |
| Pin 8 | RB2 — Bidirectional I/O port B bit 2 |
| Pin 9 | RB3 — Bidirectional I/O port B bit 3 |
| Pin 10 | RB4 — Bidirectional I/O port B bit 4 |
| Pin 11 | RB5 — Bidirectional I/O port B bit 5 |
| Pin 12 | RB6 — Bidirectional I/O port B bit 6 |
| Pin 13 | RB7 — Bidirectional I/O port B bit 7 |
| Pin 14 | VDD — Positive supply (5 V regulated from internal HV regulator) |
| Pin 15 | OSC2/CLKOUT — Oscillator output / clock out |
| Pin 16 | OSC1/CLKIN — Oscillator input / external clock in |
| Pin 17 | RA0 — Bidirectional I/O port A bit 0 |
| Pin 18 | RA1 — Bidirectional I/O port A bit 1 |
Typical Applications
PIC16HV540-04I/P is suitable for 7 applications: Battery-Powered Sensor Nodes, Smoke and Fire Detectors, LED Lighting Controllers, Small Appliance Control Boards, Replacement of Discrete Logic, Toys and Educational Electronics, Industrial Timer and Counter Modules.
Battery-Powered Sensor Nodes
The PIC16HV540-04I/P's integrated HV shunt regulator accepts 3.5 V to 15 V battery supplies directly without external regulation, simplifying battery-powered sensor designs. With 25 bytes RAM, 12 I/O pins, and a 200 ns instruction cycle at 4 MHz, it can sample sensors, run wake-up logic, and transmit data via I/O bit-banging. The wide supply range suits 9 V battery or multi-cell alkaline stacks, reducing BOM cost and board area.
Recommended
Smoke and Fire Detectors
The PIC16HV540-04I/P is well-suited for ionization-type smoke detectors where the integrated HV regulator simplifies the 9 V battery interface. The brown-out detect and watchdog timer ensure reliable operation across the battery discharge curve, while 12 I/O pins support the ionization chamber input, piezo buzzer driver, and LED indicators. Industrial temperature range supports garage and basement installations.
Recommended
LED Lighting Controllers
For decorative and architectural LED controllers, the PIC16HV540-04I/P's 12 I/O pins can drive multiple LED channels via direct connection or simple transistor drivers. The OTP memory and integrated HV regulator suit cost-driven consumer products where firmware is finalized at production. Its 4 MHz speed easily handles PWM dimming, color cycling, and simple pattern algorithms.
Recommended
Small Appliance Control Boards
In coffee makers, toasters, and simple kitchen appliances, the PIC16HV540-04I/P replaces discrete logic with a programmable controller. Its 18-pin PDIP package is friendly to hand-soldered or low-volume production runs. The integrated HV regulator simplifies connection to rectified mains-derived DC supplies, while the watchdog timer prevents hang states in unattended operation.
Recommended
Replacement of Discrete Logic
Designers migrating from 74HC-series glue logic to a programmable controller can drop in the PIC16HV540-04I/P and consolidate multiple gates, timers, and state machines into firmware. The 33 single-word instructions are easy to learn, and the OTP memory is programmed once and locked, protecting intellectual property. Industrial temperature range suits outdoor enclosures and automotive under-hood modules.
Recommended
Toys and Educational Electronics
The PIC16HV540-04I/P is widely adopted in cost-sensitive educational and toy products where OTP memory and integrated HV regulator reduce per-unit cost. With 12 I/O pins, designers can drive motors, LEDs, speakers, and simple user inputs. The 4 MHz clock and RISC architecture provide deterministic response time, important for interactive play patterns.
Recommended
Industrial Timer and Counter Modules
In industrial timer modules and pulse counters, the PIC16HV540-04I/P's watchdog timer, brown-out detect, and wide supply range support reliable 24/7 operation in factory environments. The 12-bit instruction set enables 16-bit internal counters via software, and the 4 MHz clock provides 1 microsecond resolution for timing critical events. Industrial temperature rating handles unheated enclosures.
Recommended
Recommended Products Summary
Engineering reference data for PIC16HV540-04I/P — comparison, design guidance, and compliance information.
Selection Guide
Comparison with Alternatives
| Parameter | This Product | PIC16HV540-04/P | PIC16HV540/JW | PIC16HV540-04I/SO | PIC16C54C-04/P | PIC16C54A-04/P |
|---|---|---|---|---|---|---|
| Brand | Microchip Technology | Microchip Technology | Microchip Technology | Microchip Technology | Microchip Technology | Microchip Technology |
| Package | PDIP-18 | PDIP-18 - same | PDIP-18 (windowed) | SOIC-18 | PDIP-18 - same | PDIP-18 - same |
| Clock Frequency | 4 MHz | 4 MHz | 20 MHz max | 4 MHz | 4 MHz | 4 MHz |
| Program Memory | 768 bytes OTP | 768 bytes OTP | 768 bytes EPROM (windowed) | 768 bytes OTP | 768 bytes OTP | 768 bytes OTP |
| Data RAM | 25 bytes | 25 bytes | 25 bytes | 25 bytes | 25 bytes | 25 bytes |
| I/O Pins | 12 | 12 | 12 | 12 | 12 | 12 |
| Integrated HV Regulator | Yes (3.5-15 V input) | Yes | Yes | Yes | No (external 5V required) | No (external 5V required) |
| Operating Temperature | -40C to +85C | 0C to +70C | 0C to +70C (windowed) | -40C to +85C | 0C to +70C | 0C to +70C |
Key Differentiators
- Integrated high-voltage shunt regulator accepts 5-15 V supply directly (vs PIC16C54C-04/P)
- Industrial -40C to +85C temperature range (vs PIC16HV540-04/P)
- Through-hole PDIP-18 package for hand-soldering and prototyping (vs PIC16HV540-04I/SO)
Design Notes
The PIC16HV540-04I/P integrates a high-voltage shunt regulator that accepts 3.5 V to 15 V on the VDD pin and internally regulates to 5 V. Decouple VDD with a 100 nF ceramic capacitor close to the pin and add a 10 uF bulk capacitor if the supply is shared with noisy loads. Do not connect an external 5 V rail directly; the HV regulator is internal and uses a shunt topology. Estimated: at 15 V input and 5 mA load, the shunt regulator dissipates roughly (15-5) * 0.005 = 50 mW, which is safe for the PDIP-18 package without a heatsink.
Place the oscillator crystal or resonator within 1 cm of OSC1 (pin 16) and OSC2 (pin 15), with the load capacitors grounded to a clean VSS trace. Keep high-current switching traces (relays, LEDs) away from the oscillator pins to prevent injected noise. The MCLR pin (pin 4) should have a 10 kohm pull-up to VDD; if not used, leave it tied directly to VDD per datasheet recommendation.
OTP memory can be programmed only once; ensure firmware is fully validated on a windowed PIC16HV540/JW before committing to OTP production units. The -04 speed grade limits operation to 4 MHz maximum; do not substitute a -20 grade crystal without verifying instruction cycle timing. Brown-out detect voltage level is fixed in this family; if a different threshold is needed, external supervisor ICs (such as MCP100) must be used.
Estimated: at maximum supply voltage 15 V and 5 mA active current, the PIC16HV540-04I/P dissipates roughly (15-5) * 0.005 = 50 mW through the internal shunt regulator. The PDIP-18 package has theta_JA around 70 C/W, resulting in a junction temperature rise of about 3.5 C above ambient - well within the 125 C absolute maximum. No external heatsink is required for normal operation.
Compliance Information
RoHS and lead-free per Microchip product page; PIC16HV540 family is not AEC-Q100 qualified (not designed for automotive safety-critical applications). For automotive-grade replacements consider PIC16F18446 or similar newer flash MCUs.