Skip to content

feat(nrf52): optional external QSPI LittleFS filesystem#10139

Draft
benallfree wants to merge 9 commits intomeshtastic:developfrom
MeshEnvy:feat/nrf-external-flash
Draft

feat(nrf52): optional external QSPI LittleFS filesystem#10139
benallfree wants to merge 9 commits intomeshtastic:developfrom
MeshEnvy:feat/nrf-external-flash

Conversation

@benallfree
Copy link
Copy Markdown

@benallfree benallfree commented Apr 12, 2026

This PR creates a LittleFS partition on external flash for nRF devices that support it and exposes a new extFs global to access it. We introduce a new flag, MESHTASTIC_EXTERNAL_FLASH_FS that will initialize a LittleFS partition on external flash.

Co-author: @GoatsAndMonkeys

Prerequisites:

Note that if MESHTASTIC_EXTERNAL_FLASH_FS is defined but EXTERNAL_FLASH_USE_QSPI is not, it is assumed that external flash is not supported and thus this all becomes a noop. Both must be defined for this feature to work.

Boards with external flash hard-wired from factory

The following boards have MESHTASTIC_EXTERNAL_FLASH_FS set by default in this PR because
their QSPI flash chip is physically soldered on every unit shipped:

Board env Product Chip
t-echo Lilygo T-Echo WP25R1635F / MX25R1635F (2 MB)
t-echo-lite Lilygo T-Echo Lite ZD25WQ32CEIGR (4 MB)
t-echo-plus Lilygo T-Echo Plus MX25R1635F (2 MB)
nano-g2-ultra B&Q Consulting Nano G2 Ultra W25Q16JV (2 MB)
rak_wismeshtap RAK WisMesh TAP IS25LP080D (1 MB)

Boards with QSPI capability but NOT enabled in this PR

The following boards define EXTERNAL_FLASH_USE_QSPI and name a chip, but the chip's presence on every shipped unit could not be confirmed from public hardware documentation (modular ecosystems, development kits, community boards). Board maintainers should add #define MESHTASTIC_EXTERNAL_FLASH_FS to their variant.h once confirmed:

Board env Notes
rak4631 and all rak4631_* variants WisBlock modular — flash is on the base board, not the core module; not all base board configurations include it
rak3401_1watt RAK module variant — flash presence depends on carrier board
heltec_mesh_node_t114 Heltec — likely soldered but not verified
canaryone Community board — not verified
meshlink Community board — not verified
meshtiny Community board — not verified
monteops_hw1 Community board — not verified
muzi_base Community board — not verified
gat562_mesh_trial_tracker Custom tracker — not verified
seeed_wio_tracker_L1 / _eink Seeed — likely soldered but not verified
seeed_solar_node Seeed — not verified
seeed_xiao_nrf52840_kit XIAO kit — flash may be kit accessory only
ELECROW-ThinkNode-M1 / M6 Elecrow — not verified

🤝 Attestations

  • I have tested that my proposed changes behave as described.
  • I have tested that my proposed changes do not cause any obvious regressions on the following devices:
    • Heltec (Lora32) V3
    • LilyGo T-Deck
    • LilyGo T-Beam
    • RAK WisBlock 4631
    • Seeed Studio T-1000E tracker card
    • Other (please specify below)

FILE_O_WRITE on nRF52 (Adafruit LittleFS) appends to existing files
rather than truncating. Remove the file before opening for write so
repeated XModem uploads always produce the correct file size.

Made-with: Cursor
@benallfree benallfree marked this pull request as draft April 13, 2026 04:39
@benallfree benallfree marked this pull request as draft April 13, 2026 04:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant