Repository navigation
feat(esp8266): embedded LittleFS is automatic; retire FL_ESP8266_EMBEDDED_FS (#4947) - #4953
Merged
Merged
Conversation
…DDED_FS The on-chip LittleFS backend was gated behind FL_ESP8266_EMBEDDED_FS (src/platforms/embedded_fs.h) while ESP32 got it unconditionally. Select the backend the same way on both platforms. - embedded_fs.h: . The adapter (platforms/arduino/fs/embedded_fs_arduino.hpp) already guards on FL_HAS_INCLUDE(<LittleFS.h>)/<FS.h> and degrades to a null filesystem when absent, so no opt-in define is needed. The gate existed only to work around an empty littlefs submodule in fbuild's cached ESP8266 core; fbuild now packages it (FastLED/fbuild#1380). - asset_scanner.embedded_fs_defines(): always empty now (single decision point kept for the future); the staged -DFL_ESP8266_EMBEDDED_FS is gone and the storage-requirement report says the backend is automatic. - Update the three tests that asserted the define was injected. Verified: bash compile esp8266 --examples Blink succeeds and the fl.fs.embedded TU's dep file now lists the core's LittleFS.h, i.e. the real backend is selected with no define. Refs #4947, #4949.
|
Caution Review failedThe pull request is closed. Finishing Touches
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Member
Author
Memory check (
|
| master | this stack | Δ | |
|---|---|---|---|
| image_flash | 264,671 B | 264,667 B | -4 B |
| attributed flash | 203,252 B | 203,249 B | -3 B |
| RAM | 6,808 B | 6,808 B | 0 B |
No memory regression: the unused ESP8266 engines are dead-stripped (template selection + linker elimination), so naming none of them costs ~nothing, as intended (#2428).
TKDFusion
pushed a commit
to TKDFusion/Software-FastLED-FASTLED
that referenced
this pull request
Nov 8, 2026
…rule (FastLED#4940) Umbrella for the ESP8266 define-elimination epic (FastLED#4949): state the rule and guard it. - agents/docs/cpp-standards.md: new REQUIRED section 'Driver selection is by template, never a code-enabling define' with the BusTraits/BusSupports shape and the retired offenders (FASTLED_ESP8266_UART, FASTLED_ALL_PINS_HARDWARE_SPI, FL_ESP8266_EMBEDDED_FS). - ci/lint_cpp/driver_enable_define_checker.py (new): a Python FileContentChecker that flags a preprocessor guard wrapping a 'platforms/...' include under src/platforms/** in an FL_*/FASTLED_* macro -- the code-enabling-define shape. The guards shipping today are grandfathered in driver_enable_define_amnesty.txt (regenerate with --generate-amnesty); new ones fail. Registered in run_all_checkers.py. - ci/tests/test_driver_enable_define_checker.py (new): flagged/allowed cases plus a tree-wide check that the amnesty still covers src/platforms. Wired into PY_SMOKE (guard in test_native_ci_modes.py bumped 9 -> 10). The three conversions land in FastLED#4951 / FastLED#4952 / FastLED#4953; this PR is the rule + guard. Refs FastLED#4940, FastLED#4949.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Stacked on #4952 (#4944). Fixes #4947. Part of #4949.
Problem
src/platforms/embedded_fs.hgated the on-chip LittleFS backend behindFL_ESP8266_EMBEDDED_FSwhile ESP32 got it unconditionally — a code-enablingdefine per the tracking issue.
Change
embedded_fs.h—#if defined(FL_IS_ESP32) || defined(FL_IS_ESP8266).The adapter (
platforms/arduino/fs/embedded_fs_arduino.hpp) already guards onFL_HAS_INCLUDE(<LittleFS.h>)/<FS.h>and degrades to a null filesystemwhen the library is absent, so the change is safe even on a core without
littlefs. The gate existed only to work around an empty littlefs submodule in
fbuild's cached ESP8266 core; fbuild now packages it (ESP8266 core cached without the littlefs submodule; any <LittleFS.h> include fails fbuild#1380).
asset_scanner.embedded_fs_defines()— always empty now (the singledecision point is kept for the future); the staged
-DFL_ESP8266_EMBEDDED_FSis gone and
announce_storage_requirements()reports the automatic selection.Test plan / evidence
bash compile esp8266 --examples Blinksucceeds, and thefl.fs.embeddedTU's dependency file now lists the core's
LittleFS/src/LittleFS.h— i.e. thereal backend is selected with no define (null fallback not taken).
pytest ci/tests/test_asset_scanner.py ci/tests/test_source_manager.py ci/tests/test_embedded_fs_build_defines.py— 44 passed.(needs a board).