PIC24HJ128GP502-E/SP - 16-bit 40 MIPS 128KB Flash MCU | Microchip
MPN: PIC24HJ128GP502-E/SP ✓ Active| Qty | Unit Price | Extended |
|---|---|---|
| 1 | $7.2 | $7.20 |
| 10 | $6.48 | $64.80 |
| 100 | $5.76 | $576.00 |
| 500 | $5.18 | $2,590.00 |
| 1,000 | $4.61 | $4,610.00 |
PIC24HJ128GP502-E/SP Overview
The PIC24H is a 16-bit modified Harvard architecture MCU that combines high-throughput DSP-style computation with deterministic interrupt response. As a 16-bit microcontroller, the PIC24H bridges the gap between 8-bit PIC MCUs (PIC16/PIC18) and 32-bit Cortex-M parts, offering more code space, wider data paths, and richer peripherals while remaining within the familiar MPLAB X / XC16 toolchain. It is pin-compatible with the dsPIC33F DSP family, simplifying migration for designs that need DSP extensions later.
Key features include 21 general-purpose I/O pins, two 3-wire SPI modules, two I2C modules, two UART modules with FIFO, an Enhanced CAN (ECAN) module, 16-bit timers, an input capture module, and a parallel master port. The 16-bit instruction set is highly orthogonal, and C-compiled code is significantly denser than equivalent 32-bit Cortex-M0 implementations, lowering BOM cost for code-intensive applications.
Typical applications include industrial motor control (BLDC, PMSM, stepper), automotive body and chassis ECUs, solar inverter control, UPS systems, and advanced sensor hubs. The combination of deterministic 40 MIPS compute, integrated CAN, and extended temperature grade (-40 °C to +125 °C) makes the device particularly well-suited to automotive AEC-Q100 designs and industrial automation.
When designing with this part, allocate a 10 µF plus 0.1 µF bulk-decoupling network near the AVDD/VDD pins, route the analog and digital ground planes as a single net split under the MCU, and follow the ECAN bus termination guidance in the family reference manual. For automotive designs, validate against the AEC-Q100 grade and refer to the dsPIC33F/PIC24H family reference manual sections for DMA and PMP peripheral configuration.
This page synthesizes distributor pricing, parametric comparison with same-family alternatives, and practical design notes not found in the standalone datasheet, enabling engineers to make informed selection and replacement decisions at a glance.
Drop-in alternatives for PIC24HJ128GP502-E/SP — 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 PIC24HJ128GP502-E/SP (same form factor and footprint) — differing in Operating Temperature, Package, Timers, ADC, Core Architecture.
Quick Comparison Tool — Select alternative parts for side-by-side comparison:
PIC24HJ128GP502-I/SP
✅ Drop-In✓ In Stock
$4.61 / Unit
View Datasheet →DSPIC33FJ128GP802-I/SP
✅ Drop-In✓ In Stock
$4.95 / Unit
View Datasheet →PIC24HJ128GP504-I/SP
✅ Drop-In📋 Reference alternative (not in catalog)
PIC24HJ128GP502-E/SO
✅ Drop-In📋 Reference alternative (not in catalog)
PIC24HJ128GP502-E/ML
✅ Drop-In📋 Reference alternative (not in catalog)
PIC24HJ64GP502-I/SP
✅ Drop-In📋 Reference alternative (not in catalog)
DSPIC33FJ128MC802-I/SP
✅ Drop-In✓ In Stock
$5.1 / Unit
View Datasheet →PIC24HJ128GP502-E/SP Maximum Ratings & Electrical Characteristics
| Core Architecture | PIC24H 16-bit modified Harvard |
| Core Size | 16-bit |
| Maximum CPU Speed | 40 MIPS (40 MHz) |
| Program Memory (Flash) | 128 KB (43K x 24) |
| RAM Size | 8 KB |
| Operating Voltage (VDD) | 3.0 V to 3.6 V |
| I/O Pins | 21 |
| Package | 28-pin SPDIP (0.300") |
| Mounting Type | Through Hole |
| Operating Temperature | -40 °C to +125 °C (Extended, -E) |
| ADC | 12-bit, up to 10 channels |
| Timers | 5 x 16-bit timers/counters |
| Communication Interfaces | 2x SPI, 2x I2C, 2x UART, 1x ECAN |
| Pin-Compatible Family | dsPIC33F (DSP extensions) |
| AEC-Q100 Qualified | Yes (Extended temperature, automotive grade) |
| RoHS Status | Compliant |
| Programming Toolchain | MPLAB X IDE + XC16 compiler |
PIC24HJ128GP502-E/SP Pin Configuration
| Pin 1 | MCLR — Master Clear (Reset) input, active low |
| Pin 2 | RA0 — Port A bit 0 / AN0 |
| Pin 3 | RA1 — Port A bit 1 / AN1 |
| Pin 4 | RB0 — Port B bit 0 / AN2 |
| Pin 5 | RB1 — Port B bit 1 / AN3 |
| Pin 6 | RB2 — Port B bit 2 / AN4 |
| Pin 7 | RB3 — Port B bit 3 / AN5 |
| Pin 8 | VSS — Ground reference |
| Pin 9 | OSC1 — Crystal oscillator input / CLKI |
| Pin 10 | OSC2 — Crystal oscillator output / CLKO |
| Pin 11 | RB4 — Port B bit 4 / AN6 |
| Pin 12 | RB5 — Port B bit 5 / AN7 |
| Pin 13 | RB6 — Port B bit 6 / AN8 / PGEC1 |
| Pin 14 | RB7 — Port B bit 7 / AN9 / PGED1 |
| Pin 15 | AVSS — Analog ground |
| Pin 16 | AVDD — Analog positive supply |
| Pin 17 | RB9 — Port B bit 9 / AN11 |
| Pin 18 | RC0 — Port C bit 0 |
| Pin 19 | RC1 — Port C bit 1 |
| Pin 20 | RC2 — Port C bit 2 |
| Pin 21 | RC3 — Port C bit 3 |
| Pin 22 | RC4 — Port C bit 4 |
| Pin 23 | RC5 — Port C bit 5 |
| Pin 24 | RC6 — Port C bit 6 / TX |
| Pin 25 | RC7 — Port C bit 7 / RX |
| Pin 26 | RB10 — Port B bit 10 |
| Pin 27 | RB11 — Port B bit 11 |
| Pin 28 | VDD — Positive supply (3.0-3.6V) |
Typical Applications
PIC24HJ128GP502-E/SP is suitable for 6 applications: Industrial Motor Control (BLDC/PMSM), Automotive Body and Chassis ECU, Solar Inverter and Power Conversion, Uninterruptible Power Supply (UPS) Control, Industrial Sensor Hub with CAN Bus, HVAC and Building Automation Controller.
Industrial Motor Control (BLDC/PMSM)
The PIC24HJ128GP502-E/SP's 40 MIPS core, 12-bit ADC, and dedicated motor-control peripherals (6 PWM channels via the MCPWM module on related parts, ECAN feedback) make it well-suited for sensorless and sensored BLDC/PMSM drives in industrial pumps, fans, and servo amplifiers. At 40 MIPS the device executes field-oriented control (FOC) loops in under 25 µs with deterministic interrupt latency. The integrated ECAN module provides real-time torque/speed telemetry over CANopen or DeviceNet. The extended -40 °C to +125 °C grade supports outdoor and cabinet-mounted installations where ambient temperatures approach 100 °C. Designers can reuse firmware across the same die family (PIC24HJ128GP504, dsPIC33FJ128GP802) without PCB changes, simplifying product-line scaling from low-end 64 KB Flash variants to full 128 KB Flash applications.
Recommended
Automotive Body and Chassis ECU
The PIC24HJ128GP502-E/SP's AEC-Q100 qualification, -40 °C to +125 °C operating range, and integrated ECAN module make it a strong fit for body controllers, HVAC modules, lighting ECUs, and seat/door-zone modules. The 128 KB Flash accommodates CANopen/J1939 stack + application logic, while 8 KB RAM is sufficient for diagnostic buffers. The 40 MIPS core handles LIN, CAN, and low-speed peripheral polling simultaneously without saturating. Pin-compatibility with dsPIC33F devices lets automotive engineers migrate to DSP-based fuel-pump or electronic throttle-control variants without re-laying out the PCB. The 28-pin SPDIP package remains common in automotive Tier-1 designs where through-hole assembly simplifies in-vehicle harness integration and field service.
Recommended
Solar Inverter and Power Conversion
Solar micro-inverters and string inverters benefit from the PIC24HJ128GP502-E/SP's 12-bit ADC (10 channels) to sample PV input voltage, MPPT current, grid voltage, and output current at synchronous rates required for MPPT loops. At 40 MIPS the device can execute perturb-and-observe or incremental-conductance MPPT with sub-millisecond loop times. The ECAN bus enables inverter-to-string-communications in 3-3 HMI/aggregator topologies. The extended temperature grade (-40 °C to +125 °C) ensures operation inside the inverter housing where ambient temperatures regularly exceed 70 °C under full solar load. The 128 KB Flash hosts the control law, grid-tie synchronisation code, and Modbus/CANopen protocols without needing external memory.
Recommended
Uninterruptible Power Supply (UPS) Control
Online UPS systems use the PIC24HJ128GP502-E/SP to coordinate inverter control, battery management, and front-panel user interface. The 40 MIPS core runs the voltage-mode or current-mode control loops at 16 kHz switching frequency with margin for housekeeping tasks. The 12-bit ADC samples battery voltage, charge current, output voltage, and temperature for state-of-charge estimation. ECAN provides networked monitoring of multiple UPS modules in parallel-redundant configurations. The extended temperature grade supports inside-the-cabinet deployment with reduced cooling. The 28-SPDIP package allows service technicians to swap boards without hot-air rework tools, which is a benefit in 24/7 data-center UPS installations.
Recommended
Industrial Sensor Hub with CAN Bus
Industrial sensor hubs aggregate multiple analog/digital sensors and publish processed data over CAN. The PIC24HJ128GP502-E/SP's 21 GPIO and 10-channel 12-bit ADC accommodate up to 10 analog sensor inputs (pressure, temperature, flow, vibration) plus digital I/O for switch and encoder signals. ECAN transmission of CANopen or J1939 messages runs alongside the ADC scan loop without dropped samples. The 128 KB Flash supports protocol stacks plus sensor calibration tables; the 8 KB RAM holds DMA buffers for 1 kHz vibration-data capture. The extended temperature range suits outdoor process-control installations near furnaces or chillers. Pin-compatibility with smaller 64 KB Flash variants (PIC24HJ64GP502-I/SP) lets engineers downsize BOM cost for sensor-hub variants with fewer features.
Recommended
HVAC and Building Automation Controller
Building-automation controllers for variable-air-volume (VAV) boxes, fan-coil units, and rooftop units use the PIC24HJ128GP502-E/SP to run PID loops, schedule occupancy events, and communicate over BACnet or Modbus. The 40 MIPS performance is more than sufficient for simultaneous PID + scheduling + communication tasks. The 12-bit ADC samples discharge-air temperature, duct pressure, and CO2 sensor inputs. The extended temperature grade supports mechanical-room installations where temperatures swing widely. The 28-SPDIP package is preferred by HVAC OEMs that prefer through-hole assembly for field-serviceable controller boards. The 128 KB Flash stores BACnet object databases without needing external EEPROM.
Recommended
Recommended Products Summary
Engineering reference data for PIC24HJ128GP502-E/SP — comparison, design guidance, and compliance information.
Selection Guide
Comparison with Alternatives
| Parameter | This Product | PIC24HJ128GP502-I/SP | dsPIC33FJ128GP802-I/SP | PIC24HJ128GP504-I/SP | dsPIC33FJ128MC802-I/SP |
|---|---|---|---|---|---|
| Brand | Microchip Technology | Microchip Technology | Microchip Technology | Microchip Technology | Microchip Technology |
| Package | 28-SPDIP (0.300") | 28-SPDIP (0.300") | 28-SPDIP (0.300") | 28-SPDIP (0.300") | 28-SPDIP (0.300") |
| Flash Memory | 128 KB | 128 KB | 128 KB | 256 KB | 128 KB |
| RAM Size | 8 KB | 8 KB | 16 KB | 8 KB | 16 KB |
| Max CPU Speed | 40 MIPS / 40 MHz | 40 MIPS / 40 MHz | 40 MIPS / 40 MHz | 40 MIPS / 40 MHz | 40 MIPS / 40 MHz |
| Operating Temperature | -40 °C to +125 °C (E) | -40 °C to +85 °C (I) | -40 °C to +85 °C (I) | -40 °C to +85 °C (I) | -40 °C to +85 °C (I) |
| ADC | 12-bit, 10 ch | 12-bit, 10 ch | 12-bit, 10 ch | 12-bit, 13 ch | 12-bit, 6 ch |
| DSP Engine | No | No | Yes (DSP) | No | Yes (DSP, motor PWM) |
| ECAN Module | Yes | Yes | Yes | Yes | Yes |
Key Differentiators
- Higher Flash and ECAN integration vs lower-tier PIC24F (vs PIC24FJ64GA002-E/SO)
- Extended +125 °C temperature grade vs +85 °C industrial-only parts (vs PIC24HJ128GP502-I/SP)
- Pin-compatible DSP upgrade path via dsPIC33F family (vs dsPIC33FJ128GP802-I/SP)
Design Notes
Decouple VDD with a 10 µF tantalum or ceramic bulk capacitor in parallel with a 0.1 µF ceramic placed within 5 mm of the VDD pin. Place a separate 10 µF + 0.1 µF network on AVDD, and connect AVSS to VSS at a single point under the MCU to avoid ground-loop noise coupling into the ADC. The on-chip voltage regulator requires a 4.7 µF low-ESR capacitor on Vcap (when present on larger packages) to maintain core-rail stability.
Route the ECAN bus differential pair (CANTX/CANRX) as a 100-ohm differential pair with 60 Ω single-ended impedance, keep stubs < 5 mm, and place a 120 Ω termination resistor at each end of the bus. Route the analog ADC inputs (ANx) away from digital switching traces; use a guard trace connected to AVSS between analog and digital nets to suppress crosstalk. Keep oscillator traces short and surrounded by VSS.
Do not exceed 3.6 V on VDD or AVDD - the PIC24H does not have 5V tolerance on digital I/O. Use a 3.3 V LDO (e.g., MCP1700) rather than a 5 V supply with a level shifter. The -E temperature grade +125 °C requires industrial-grade passives and 105 °C-rated electrolytics on adjacent power rails. Enable the watchdog timer (WDT) in software for unattended installations; the default POR is not sufficient for safety-critical designs.
For SPI peripherals clocked above 10 MHz, add 33 Ω series resistors at the SCK/MOSI outputs to dampen reflections from capacitive loads on multi-device buses. For I2C, select 4.7 kΩ pull-ups at 400 kHz Fast-Mode and 1 kΩ pull-ups at 1 MHz Fast-Mode-Plus to maintain rise-time budget. For UART RS-232/RS-485 links over 1 meter, use shielded cable and add TVS diodes (e.g., PESD5V0S1BA) on the lines.
Compliance Information
AEC-Q100 qualified (extended temperature grade -E suffix). RoHS and REACH compliant per Microchip product declaration. Lead-free matte-tin finish on PDIP package.