fix(techo-lite): remove duplicate EXTERNAL_FLASH_DEVICES definition#2719
fix(techo-lite): remove duplicate EXTERNAL_FLASH_DEVICES definition#2719jirogit wants to merge 2 commits into
Conversation
|
Hey, thanks for the PR. As far as I'm aware, So I can't see how changing this will make any difference to LittleFS. However, I'll tag @oltaco as we probably should remove the define that's incorrect. |
|
Thank you for the clarification! I wasn't aware that CustomLFS uses The fix still seems worthwhile to avoid confusion for anyone reading |
|
Liam is correct, we don't have to define it at all; its all handled in CustomLFS. The T-Echo Lite does have QSPI flash as you found, but it isn't currently active for meshcore. Wouldn't hurt to just strip out the EXTERNAL_FLASH_DEVICES definition altogether since we don't need it even when QSPI flash support is added for the board. |
variant.h defines EXTERNAL_FLASH_DEVICES twice: - First (correct): ZD25WQ32CEIGR (32Mbit = 4MB, matches actual hardware) - Second (incorrect): MX25R1635F (16Mbit = 2MB, T-Echo non-Lite chip) Due to C preprocessor behavior, the second definition silently overrides the first, causing firmware to initialize the wrong flash chip. This can result in LittleFS operating incorrectly on T-Echo Lite hardware. Remove the erroneous second definition. Also fix missing newline at end of file.
…rely Per review feedback from @liamcottle and @entr0p1, EXTERNAL_FLASH_DEVICES is not used by MeshCore firmware — CustomLFS determines the flash chip via JEDEC ID at runtime instead. Removing the definition entirely rather than keeping the (now-confirmed-unnecessary) correct value. Also removes EXTERNAL_FLASH_USE_QSPI, which was paired with the same define.
70ee434 to
5de6512
Compare
|
Thanks both for the input — I've updated this PR to remove EXTERNAL_FLASH_DEVICES/EXTERNAL_FLASH_USE_QSPI entirely from lilygo_techo_lite/variant.h rather than just fixing the duplicate. I checked and EXTERNAL_FLASH_USE_QSPI isn't referenced anywhere outside variant.h files either, so it looked equally safe to drop. Verified build success on LilyGo_T-Echo-Lite_non_shell_companion_radio_ble. While looking into this, I noticed EXTERNAL_FLASH_DEVICES is still defined in 22 other variant.h files across the repo (e.g. rak4631, heltec_t114, wio-tracker-l1, lilygo_techo). If it's genuinely unused firmware-wide per CustomLFS's JEDEC ID detection, would it be worth opening a separate issue to track cleanup across those too? Happy to open one if useful, just didn't want to scope-creep this PR. |
Problem
variants/lilygo_techo_lite/variant.hdefinesEXTERNAL_FLASH_DEVICEStwice:Both definitions were introduced simultaneously in the initial commit
adding T-Echo Lite support (b11f084). Per LILYGO's official schematic,
ZD25WQ32CEIGRis the only flash chip used on T-Echo Lite hardware.Fix
Remove the erroneous second definition (lines 98–99) to avoid confusion
for anyone reading the variant file.
Testing
Built
LilyGo_T-Echo-Lite_non_shell_companion_radio_ble— Success.Also fixes missing newline at end of file.