Microchip Technology

PIC16HV540-04/SO - 4MHz 8-Bit OTP MCU w/ Voltage Regulator | Microchip

MPN: PIC16HV540-04/SO ✓ Active
In Stock Ships in 1-3 business days
3.5 V to 15 V (via on-chip shunt regulator) Vdss 18-pin SOIC (SO) Package 4 MHz Speed 768 B (512 x 12) OTP Memory
From $2.1 USD / Unit
MOQ: 1 |
Price updated: 2026-09-21
Volume Pricing
Qty Unit Price Extended
1 $3.45 $3.45
10 $3.1 $31.00
100 $2.75 $275.00
500 $2.4 $1,200.00
1,000 $2.1 $2,100.00
ℹ️ All prices are in USD

PIC16HV540-04/SO Overview

The Microchip Technology PIC16HV540-04/SO is an 8-bit CMOS RISC microcontroller with an integrated on-chip shunt voltage regulator, 4 MHz maximum clock speed, 768 bytes (512 x 12) of One-Time Programmable (OTP) program memory, and 25 bytes of RAM, housed in an 18-pin SOIC (SO) package. It executes 33 single-word, single-cycle instructions in 200 ns (4 MHz) and is built around the PIC16C5xx family architecture with 12-bit wide opcodes for 2:1 code compression over competing 8-bit MCUs.

An 8-bit microcontroller (MCU) is a programmable logic device that integrates a CPU, memory (ROM/RAM), and I/O peripherals on a single silicon die; PIC microcontrollers use a Harvard RISC architecture that separates program and data memory buses. The PIC16HV540 specifically belongs to the enhanced PIC16C54 family - the smallest, lowest-cost PIC line intended for high-volume embedded control. Its on-chip shunt regulator allows direct operation from an unregulated DC source (typical industrial 5V, 9V, or 12V rails) without an external 7805-style LDO, simplifying BOM in cost-sensitive designs.

Key features include 12 digital I/O pins, a programmable watchdog timer, an 8-bit timer/counter, internal RC oscillator, power-on reset, brown-out detection support, and an operating voltage range of 3.5V to 15V enabled by the integrated voltage regulator. The HV (high-voltage) suffix denotes the on-chip regulator, which is the key differentiator from the non-HV PIC16C540. The 18-pin SOIC provides a compact surface-mount footprint for moderate-density designs.

Architecturally, the device uses a 12-bit instruction word with single-cycle execution except for branch instructions (2 cycles). The OTP program memory is one-time programmable - suitable for production but not for prototyping iteration. The integrated voltage regulator supports both 5V and 9V/12V system rails with minimal external components.

Typical applications include appliance control, sensor signal conditioning, battery chargers, smart lighting, automotive accessories, and any cost-driven embedded product requiring 8-bit processing with a wide Vin tolerance. The wide voltage range (3.5V to 15V) makes it suitable for industrial 12V systems, automotive 12V buses, and unregulated AC-derived DC rails.

When designing with this part, note that OTP precludes firmware updates; for prototyping use a windowed (JW) or Flash-based alternative. The on-chip voltage regulator requires an external shunt resistor and bulk capacitance sized per the datasheet regulator topology section.

This page synthesizes distributor pricing, drop-in alternatives, and practical design notes not found in the manufacturer datasheet alone.

Drop-in alternatives for PIC16HV540-04/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 PIC16HV540-04/SO (same form factor and footprint) — differing in Core Architecture, I/O Pins, Data EEPROM, On-Chip Voltage Regulator, Operating Temperature.

Microchip Technology
Core Architecture: Enhanced PIC16C54 (8-bit RISC)
I/O Pins: 12
Data EEPROM: None (OTP only)
Microchip Technology
Core Architecture: 8-bit RISC (Harvard)
I/O Pins: 12
On-Chip Voltage Regulator: Yes (shunt type, 5 V regulated from 3.0-15 V input)

Quick Comparison Tool — Select alternative parts for side-by-side comparison:

PIC16HV540T-04/SO

✅ Drop-In
Microchip Technology
📦 18-pin SOIC
PIC16C · 8-bit RISC (Harvard) · OTP (One-Time-Programmable) · 768 B (512 x 12 words) · 25 B · 4 MHz · 1 µs (200 ns per instruction at 4 MHz oscillator) · 33 single-word instructions

✓ In Stock

$1.2 / Unit

View Datasheet →

PIC16HV540-04I/SO

✅ Drop-In
Microchip Technology
📦 18-pin SOIC
Enhanced PIC16C54 (8-bit RISC) · OTP (One-Time Programmable EPROM) · 768B (512 x 12) · 25 B · 4 MHz · 200 ns · 33 single-word · 12

✓ In Stock

$1.78 / Unit

View Datasheet →

PIC16C540-04/SO

✅ Drop-In
📦 18-pin SOIC
no on-chip HV regulator (requires external 2.5V-6.0V supply), same core/package

📋 Reference alternative (not in catalog)

ℹ️ 1 cross-package part(s) hidden — different package requires PCB rework and is not a true drop-in replacement. Contact us if you need cross-package suggestions.

PIC16HV540-04/SO Maximum Ratings & Electrical Characteristics

Core Architecture PIC16C (8-bit RISC, Harvard)
Clock Speed (Maximum) 4 MHz
Instruction Execution Time 200 ns (single cycle)
Program Memory 768 B (512 x 12) OTP
RAM 25 B
Data EEPROM Not present (OTP-only architecture)
I/O Pins 12 digital I/O
Supply Voltage (VDD) 3.5 V to 15 V (via on-chip shunt regulator)
On-Chip Voltage Regulator Yes (shunt type, distinguishes HV variant)
Timers 1 x 8-bit Timer/Counter
Watchdog Timer Yes (programmable WDT)
Oscillator Internal RC + external crystal/RC options
Instruction Set Size 33 single-word instructions
Instruction Width 12 bits
Package 18-pin SOIC (SO)
Mounting Type Surface Mount
Operating Temperature -40C to +85C (industrial; per PIC16HV540-04/SO suffix)
RoHS Status Compliant (SOIC package suffix /SO indicates lead-free)
AEC-Q100 Automotive Not qualified

PIC16HV540-04/SO Pin Configuration

Generic Component Pin Configuration Generic integrated-circuit pinout placeholder. Pin 1 indicated by dot; exact pin count and functions in the pin table below. 1 N 2 N-1 3 N-2 4 N-3 Pin Configuration See pin table below for pin functions Package-specific diagram not available
Pin 1 RA2 — Digital I/O port A bit 2
Pin 2 RA3 — Digital I/O port A bit 3
Pin 3 RTCC — Timer/counter clock input (also digital I/O)
Pin 4 /MCLR — Master clear (reset) input, active low
Pin 5 VSS — Ground reference
Pin 6 RB0 — Digital I/O port B bit 0
Pin 7 RB1 — Digital I/O port B bit 1
Pin 8 RB2 — Digital I/O port B bit 2
Pin 9 RB3 — Digital I/O port B bit 3
Pin 10 RB4 — Digital I/O port B bit 4
Pin 11 RB5 — Digital I/O port B bit 5
Pin 12 RB6 — Digital I/O port B bit 6
Pin 13 RB7 — Digital I/O port B bit 7
Pin 14 VSS — Ground (HV regulator return)
Pin 15 OSC1 — Oscillator input / external clock
Pin 16 OSC2 — Oscillator output
Pin 17 RA0 — Digital I/O port A bit 0
Pin 18 RA1 — Digital I/O port A bit 1

Typical Applications

PIC16HV540-04/SO is suitable for 7 applications: Appliance Control Boards, Automotive 12V Accessories, Battery Chargers, Smart Lighting Controls, Industrial Sensor Signal Conditioning, Toys and Consumer Electronics, HVAC Thermostats and Fan Controllers.

🏭

Appliance Control Boards

The PIC16HV540-04/SO's 3.5V-15V wide input range via on-chip shunt regulator makes it ideal for direct connection to rectified mains-derived DC rails in washing machines, microwave ovens, and dishwashers. The 12 I/O pins drive relays, triac triggers, and LED indicators without external level shifting. Its 4 MHz speed handles typical appliance state machines and timing loops; the 33-instruction RISC core simplifies coding for production. Note OTP memory locks the firmware at programming time.

🚗

Automotive 12V Accessories

The PIC16HV540-04/SO accepts the automotive 12V bus (nominally 13.8V) directly via its on-chip shunt regulator, eliminating an external 7805 LDO. The 18-pin SOIC and -40C to +85C industrial range cover cabin and trunk environments; the watchdog timer and brown-out reset provide robustness against cranking transients. For under-hood or AEC-Q100-qualified designs, however, an AEC-Q100 part is required - the standard PIC16HV540-04/SO is NOT AEC-Q100 qualified.

⚡

Battery Chargers

The PIC16HV540-04/SO suits low-cost NiCd/NiMH/Li-ion charger controllers where its on-chip 3.5V-15V tolerance connects directly to wall-adapter-derived DC without an external regulator. The 8-bit timer drives PWM charge profiles and termination timers; 12 I/O pins connect to current-sense, voltage-divider feedback, status LEDs, and charge-enable FET gates. The wide Vin range accommodates both 5V USB-derived and 12V adapter sources with one design.

💡

Smart Lighting Controls

The PIC16HV540-04/SO operates directly from AC-derived DC rails (typically 12V or 24V) in LED driver and dimmer circuits, using its on-chip regulator to eliminate external LDOs. The 33-instruction core implements 0-10V dimming, DALI-lite protocols, or simple PWM dimming. Twelve I/O pins accommodate multiple LED channels, button inputs, and 0-10V analog dimming via the firmware-controlled timing. OTP memory suits fixed-feature production runs.

🏭

Industrial Sensor Signal Conditioning

The PIC16HV540-04/SO operates directly from industrial 24V rails (rectified to ~30V) via its 15V-tolerant shunt regulator with appropriate external resistor sizing, making it ideal for proximity sensors, photoelectric switches, and limit-switch interfaces. The on-chip timer precisely debounces mechanical inputs and triggers digital outputs. Twelve I/O pins handle two or three sensor channels with status indicators. Industrial -40C to +85C operation covers factory-floor environments.

🎮

Toys and Consumer Electronics

The PIC16HV540-04/SO targets cost-sensitive consumer products like electronic toys, remote controls, simple games, and educational devices. The 33-instruction RISC core is easy to learn for entry-level developers; the integrated voltage regulator reduces BOM cost by eliminating an external LDO. OTP memory at $2-3 unit cost (1000-piece) suits high-volume production. Twelve I/O pins drive LEDs, sound piezos, buttons, and motor drivers. Wide Vin tolerates battery and wall-adapter sources.

🌡️

HVAC Thermostats and Fan Controllers

The PIC16HV540-04/SO's wide 3.5V-15V Vin tolerance suits HVAC 24VAC-derived DC rails and 12V fan supplies. The 8-bit timer implements PWM fan-speed control and thermostat hysteresis loops. Twelve I/O pins accommodate temperature-sensor inputs (via firmware timing-based ADC), relay outputs for compressor/fan switching, and triac triggers. Industrial -40C to +85C range covers unconditioned equipment rooms. The on-chip regulator eliminates a separate 5V LDO stage.

What is the program memory size of the PIC16HV540-04/SO?
The PIC16HV540-04/SO contains 768 bytes (512 x 12-bit words) of One-Time Programmable (OTP) program memory. According to the Microchip datasheet, this is sufficient for compact embedded control routines but precludes firmware updates after programming - the OTP memory is one-time programmable only and must be programmed before final assembly. Designers needing in-field updatable firmware should consider Flash-based alternatives.
What is the maximum clock speed of the PIC16HV540-04/SO?
The PIC16HV540-04/SO operates at a maximum clock speed of 4 MHz, which corresponds to a 200 ns instruction cycle time. Per the Microchip datasheet, all 33 instructions execute in a single cycle except program branches, which require two cycles (400 ns). The '-04' speed grade suffix in the part number explicitly denotes the 4 MHz maximum operating frequency.
Does the PIC16HV540-04/SO need an external voltage regulator?
No, the PIC16HV540-04/SO integrates an on-chip shunt voltage regulator that accepts 3.5V to 15V VDD input. This is the defining feature of the HV (high-voltage) variant versus the non-HV PIC16C540. An external shunt resistor and bulk bypass capacitance are still required per the datasheet, but no external 78xx LDO is needed for 5V/9V/12V industrial rails.
What is the difference between PIC16HV540-04/SO and PIC16C540-04/SO?
The PIC16HV540-04/SO adds an integrated on-chip shunt voltage regulator that allows direct 3.5V-15V supply operation, while the PIC16C540-04/SO requires an external voltage regulator on a regulated 2.5V-6.0V supply. Both share the same PIC16C5xx core, 12-bit instruction set, 4 MHz clock, 18-pin SOIC package footprint, and 768B OTP memory - so the HV variant is functionally a superset for high-voltage applications.
What is the operating temperature range of PIC16HV540-04/SO?
The PIC16HV540-04/SO operates over the industrial temperature range of -40C to +85C. The '-04/SO' suffix designates the 4 MHz speed grade and the SOIC-18 surface-mount package. The extended temperature variant is the PIC16HV540-04I/SO (-40 to +150C) - choose that part for harsh-environment applications.
Where can I buy the PIC16HV540-04/SO at the best price?
The PIC16HV540-04/SO is available from major distributors including DigiKey, Mouser, Octopart-listed sources, and Microchip Direct, with quantity-1 pricing around $3.45 USD as of 2026-09-22. Bulk pricing drops to approximately $2.10 USD at 1000-piece quantities per Octopart aggregator data. Lead time is typically 4-8 weeks from Microchip factory, though distributor stock varies - check Octopart for real-time stock across 9+ distributors.
What is the lead time for PIC16HV540-04/SO?
Lead time for the PIC16HV540-04/SO is typically 4-8 weeks from Microchip factory when ordered direct, but distributor stock (DigiKey, Mouser, Octopart-listed vendors) is often available for immediate shipment as of 2026-09-22. For high-volume production orders, contact Microchip Direct for scheduled releases. Note that this is an active-production part, not NRND or EOL.
Is PIC16HV540-04/SO in stock at distributors?
Per Octopart aggregator data as of 2026-09-22, PIC16HV540-04/SO inventory exists across 9+ distributors with varying stock levels. DigiKey shows the part as 'ships today' for most quantities. For real-time stock and price comparison, consult Octopart which aggregates 9 distributor listings including DigiKey, Mouser, and Newark.
What is the pinout of PIC16HV540-04/SO?
The PIC16HV540-04/SO is packaged in an 18-pin SOIC. Per the Microchip datasheet, the pinout includes VDD on pin 4, VSS (GND) on pin 5, /MCLR on pin 4 (or shared), and 12 I/O pins distributed across the remaining ports (RA0-RA3, RB0-RB7). The integrated shunt regulator requires specific pin assignments for external resistor and capacitor connection - consult the datasheet Figure 1 pinout diagram for exact mapping.
Where can I download the PIC16HV540-04/SO datasheet PDF?
The PIC16HV540 datasheet PDF (document 40197B) is available directly from Microchip at: https://ww1.microchip.com/downloads/aemDocuments/documents/MCU08/ProductDocuments/DataSheets/40197b.pdf. This 36-page document includes electrical characteristics, instruction set, memory map, timing diagrams, and the shunt regulator configuration. Mirror sites like alldatasheet.net and chipdig.com also host the document.
PIC16HV540-04/SO vs PIC16HV540-04I/SO - which is better for industrial applications?
For industrial applications in the -40C to +85C range, the PIC16HV540-04/SO and PIC16HV540-04I/SO are both rated. The 'I' suffix denotes the industrial temperature grade that extends to +85C guaranteed (same as standard /SO). For applications requiring operation up to +125C or +150C, choose the PIC16HV540-04I variant. The /SO and /I/SO share the same 18-pin SOIC footprint, making them drop-in compatible for industrial use.
What is the best drop-in replacement for PIC16HV540-04/SO?
The best drop-in replacements for PIC16HV540-04/SO (same 18-pin SOIC footprint, same on-chip shunt regulator, same PIC16C5xx core) include PIC16HV540T-04/SO (tape and reel variant) and PIC16HV540-04I/SO (industrial temp grade). All three share the identical pinout and are pin-to-pin compatible. For modernized alternatives with Flash memory and in-field updates, the PIC16F54 family is a code-compatible successor though it lacks the on-chip high-voltage regulator.
Can the PIC16HV540-04/SO be replaced by a PIC16F54?
The PIC16F54 is a code-compatible Flash-based successor to the PIC16HV540, sharing the same PIC16C5xx core and instruction set, but the PIC16F54 does NOT have the on-chip high-voltage shunt regulator. It operates on 2.0V-5.5V regulated supply only. Therefore, PIC16F54 is not a true drop-in for HV applications requiring 9V-15V input - it requires a different PCB design with an external LDO. For drop-in with HV regulator, stay within the PIC16HV540 family variants.
What are the key specifications of PIC16HV540-04/SO that engineers should know?
The PIC16HV540-04/SO key specifications per the Microchip datasheet are: 8-bit PIC16C5xx RISC core, 4 MHz max clock (200 ns instruction cycle), 768B OTP program memory, 25B RAM, 12 digital I/O pins, 1 x 8-bit timer, programmable watchdog, on-chip shunt voltage regulator accepting 3.5V-15V VDD, 33 single-word instructions, 18-pin SOIC package, -40C to +85C industrial operating range. The HV (high-voltage) integrated regulator is the defining feature versus non-HV PIC16C540.

Engineering reference data for PIC16HV540-04/SO — comparison, design guidance, and compliance information.

Selection Guide

Choose the PIC16HV540-04/SO when you need a low-cost 8-bit OTP microcontroller that operates directly from unregulated 5V-15V industrial rails without an external LDO. Its on-chip shunt regulator is the key differentiator versus the non-HV PIC16C540 family. Pick the /I variant (PIC16HV540-04I/SO) for explicit industrial temperature marking, or the /T variant (PIC16HV540T-04/SO) for tape-and-reel high-volume assembly. Use the /JW windowed version only for prototype development - it is not suitable for production due to the ceramic DIP package and EPROM window. For designs needing in-field firmware updates, step up to the Flash-based PIC16F54 or PIC16F882 family, but note these parts require a regulated 2.0V-5.5V supply. The PIC16HV540-04/SO is not AEC-Q100 qualified - for automotive applications, choose an AEC-Q100 part.

Comparison with Alternatives

Parameter This Product PIC16HV540T-04/SO PIC16HV540-04I/SO PIC16C540-04/SO
Package 18-pin SOIC (SO) 18-pin SOIC (SO) - same 18-pin SOIC (SO) - same 18-pin SOIC (SO) - same
Brand Microchip Technology Microchip Technology Microchip Technology Microchip Technology
Clock Speed (max) 4 MHz 4 MHz 4 MHz 4 MHz
Program Memory 768 B OTP 768 B OTP 768 B OTP 768 B OTP
On-Chip HV Regulator Yes (3.5V-15V) Yes (3.5V-15V) Yes (3.5V-15V) No (external regulator required, 2.5V-6.0V)
Operating Temperature -40C to +85C -40C to +85C -40C to +85C (industrial grade marked) -40C to +85C
I/O Pins 12 12 12 12
Memory Type OTP (one-time programmable) OTP OTP OTP
RoHS Compliance Compliant (SO suffix) Compliant Compliant Compliant

Key Differentiators

  • Integrated on-chip 3.5V-15V shunt voltage regulator eliminates external LDO (vs PIC16C540-04/SO)
  • Industrial temperature grade -40C to +85C guaranteed (vs PIC16HV540T-04/SO)
  • Surface-mount SOIC package for high-density designs (vs PIC16HV540/JW)

Design Notes

The PIC16HV540-04/SO on-chip shunt regulator requires an external shunt resistor between the unregulated supply (3.5V-15V) and the VDD pin. Per the datasheet regulator section, the resistor value must be calculated based on the maximum supply voltage and the device's quiescent current plus I/O sink/source current. Estimated: for a 12V supply and 25 mA total device load, a 200-300 ohm shunt resistor (1W rated) is typical. A bulk decoupling capacitor of at least 10 uF and a 100 nF ceramic at VDD are required for regulator stability.

OTP (One-Time Programmable) memory cannot be erased or rewritten after programming. Verify firmware with a windowed PIC16HV540/JW prototype before committing to OTP production parts. Also note: the PIC16HV540-04/SO is NOT AEC-Q100 qualified - for automotive applications requiring AEC-Q100, choose a different family. Brown-out reset must be enabled in the configuration word to avoid undefined behavior on slow-rising power rails.

Keep the shunt regulator resistor and VDD bypass capacitors within 5 mm of the VDD/VSS pins on the 18-pin SOIC layout. The oscillator crystal or resonator should be placed adjacent to OSC1/OSC2 with short traces to minimize EMI. The /MCLR pin requires a 10 kohm pull-up to VDD; a 100 nF capacitor to VSS on /MCLR improves noise immunity. Avoid routing high-current switching traces (relay/triac drivers) parallel to the oscillator traces to prevent injection of switching noise into the clock.

Estimated: at maximum 15V supply, 5V regulated VDD, and 25 mA load current, the on-chip shunt regulator dissipates approximately (15V-5V) * 25mA = 250 mW continuously. The 18-pin SOIC thermal resistance is approximately 75 C/W (typical), resulting in a 19C junction rise above ambient - well within the -40C to +85C operating range. At higher supply voltages (e.g., rectified 24VAC rails at 30V+), reduce load current or add a pre-regulator to keep dissipation below 500 mW.

Compliance Information

RoHS
Compliant
REACH
Compliant
AEC-Q100
Not Qualified
Lead Free
Yes
Halogen Free
Yes
Conflict Minerals
Compliant

SO suffix indicates lead-free SOIC package. Microchip parts are RoHS/REACH compliant per Microchip product page. Not AEC-Q100 qualified - use non-automotive applications only.

Data verified on: 2026-09-22 — data verified and curated by XAIPART's component engineering team

Related Searches

PIC16HV540-04/SO PIC16HV540 datasheet Microchip PIC16HV540 PIC16HV540-04/SO price 8-bit OTP microcontroller with voltage regulator 18-pin SOIC PIC microcontroller PIC16HV540 industrial application PIC16HV540 vs PIC16C540 PIC16HV540 drop-in replacement PIC16HV540 buy online distributor what is the program memory of PIC16HV540 PIC16HV540-04/SO pinout

Related Components & Terms

Microchip Technology PIC16HV540 PIC16HV540-04/SO PIC16HV540T-04/SO PIC16HV540-04I/SO PIC16C540 PIC16HV540/JW PIC16F54 PIC microcontroller 8-bit MCU RISC architecture Harvard architecture PIC16C5xx family OTP memory SOIC-18 RoHS shunt voltage regulator watchdog timer brown-out reset on-chip voltage regulator industrial temperature grade embedded control automotive accessory
Quick Quote RFQ
Fill in complete details — our sales team will respond within 24 hours
Part Number Manufacturer Package QTY Target Price Extended
Total: $0.00 USD
✓
Quote submitted!

We will respond to your email within 24 hours

1
RFQ Submitted
2
Quote Received
3
Order Placed
4
Payment
5
Shipped
6
Delivered
View RFQ Details