Add support for Puya PY25Q128HA flash chip
User description
Summary
Adds detection and support for the Puya PY25Q128HA flash chip, a W25Q128-compatible 128Mbit (16MB) SPI NOR flash commonly found on flight controllers.
Changes
Driver Support (flash_m25p16.c:102-104)
- Added JEDEC ID entry (0x856018) to
m25p16FlashConfig[]array for automatic chip detection
Documentation (Blackbox.md:123)
- Added PY25Q128HA to the list of supported flash chips
Technical Details
- JEDEC ID: 0x856018
- Manufacturer: 0x85 (Puya Semiconductor)
- Memory Type: 0x60
- Capacity: 0x18 (128Mbit)
- Geometry: 256 sectors × 256 pages × 256 bytes = 16 MByte
- Command Set: Standard W25Q128-compatible (no driver changes needed)
Testing
The PY25Q128HA uses an identical command set to the W25Q128 and other supported flash chips. The existing M25P16-compatible driver already supports all necessary operations:
- JEDEC ID detection (0x9F)
- Read/write/erase operations
- Standard timing parameters
Compatibility
This is a backwards-compatible change:
- Adds new chip detection only
- No changes to existing driver logic
- No impact on boards without this chip
- Boards with PY25Q128HA will now auto-detect the chip at boot
Files Changed
src/main/drivers/flash_m25p16.c- Added JEDEC ID entrydocs/Blackbox.md- Updated documentation
PR Type
Enhancement
Description
-
Adds JEDEC ID detection for Puya PY25Q128HA flash chip
-
Enables automatic chip recognition during initialization
-
Updates documentation with new supported flash chip
Diagram Walkthrough
flowchart LR
A["Puya PY25Q128HA<br/>JEDEC ID: 0x856018"] -- "Added to detection table" --> B["flash_m25p16FlashConfig[]"]
B -- "Auto-detection at boot" --> C["Chip Support Enabled"]
D["Documentation Updated"] -- "Lists supported chips" --> E["Blackbox.md"]
File Walkthrough
| Relevant files | |||
|---|---|---|---|
| Enhancement |
| ||
| Documentation |
|
PR Compliance Guide 🔍
All compliance sections have been disabled in the configurations.