Repository navigation
Description
Something introduced in Commit 6cc156c has broken multiple programs of mine running on multiple ESP32-S3 controllers. (I have tested and replicated this on three different controller units, all of which were Seeed XIAO ESP32-S3.)
SEVERAL UPFRONT COMMENTS
- I did not try to use any Worker Pool functionality, and I even tried (without effect) to ensure I wasn't using it by adding #define FASTLED_RMT5_DISABLE_WORKER_POOL and/or #define FASTLED_RMT5_FORCE_LEGACY_MODE 1 before #include <FastLED.h>
- I used only one pin and tested on 22x22 and 24x24 matrices (of different WS2812B components/designs)
- TL/DR; I suspect the issue involves some way in which the controller manages/processes loop() instructions as opposed to callback instructions
WHAT I NOTICED INITIALLY
- New/weird behavior with a very complex ESP32-S3 sketch that's generally been working fine for me for weeks.
- All of a sudden, my visualizers would only make it through the first ~1 to ~3 iterations of the main.cpp loop() before freezing
- The first ~1 to ~3 "frames" of whatever visualizer was running would display, with the last frame persisting in a frozen state
- There was no further processing of anything else in the main loop():
- No execution of any EVERY_N_... functions
- No serial printing of any test statements placed into the main loop() for troubleshooting purposes
- No ability to reestablish BLE connection if broken after initial connection. (The initial connection is always established through functionality originating in setup(), whereas any reconnection after the first connection is enabled from within loop().)
- However, other functionality continued:
- The BLE advertising and whatever BLE "pipes"/"sockets"/"listeners" were enabled by a call to a bleSetup() function during the main setup() remained available for a considerable (untested) duration. I could still establish an initial BLE connection well after loop() had frozen
- The controller could still receive and parse BLE messages, log those in the serial monitor, and create and send BLE receipts to the UI
- In other words, it wasn't the case that the controller crashed completely. It seems only to have stopped progressing through loop()
TEST SKETCH
To rule out anything particular in my sketch as the/a cause, I created the following brand new bare-bones sketch:
https://gist.github.com/4wheeljive/534577366c7c2dfa2bf3c8d66face210
Here's the platformio.ini I started with for that sketch:
[env:seeed_xiao_esp32s3]
platform = https://github.com/pioarduino/platform-espressif32/releases/download/54.03.20/platform-espressif32.zip
board = seeed_xiao_esp32s3
framework = arduino
lib_deps =
https://github.com/FastLED/FastLED.git
build_type = debug
debug_tool = esp-builtin
monitor_filters =
default
esp32_exception_decoder
build_flags =
-DBOARD_HAS_PSRAM
-DDEBUG
-DCORE_DEBUG_LEVEL=5
-DLOG_LOCAL_LEVEL=ESP_LOG_VERBOSE
This sketch consistently froze during the second pass through loop(). Here's the complete serial monitor output from a sample run starting After Setup End:
============ After Setup End =============
Free heap: 350496
Starting loop...
Before first/blue FastLED.show()
Free heap: 350496
After first/blue FastLED.show()
Free heap: 348512
After 500ms delay
Free heap: 348512
Before second/green FastLED.show()
Free heap: 348512
After second/green FastLED.show()
Free heap: 346528
After 500ms delay
Loop complete
Free heap: 346528
Starting loop...
Before first/blue FastLED.show()
Free heap: 346528
After first/blue FastLED.show()
Free heap: 344544
After 500ms delay
Free heap: 344544
Before second/green FastLED.show()
Free heap: 344544
Here's a longer log of serial output from when my main program was running:
https://gist.github.com/4wheeljive/cb7765614a25671aef82c084a1125f31
Note all of the BLE activity and callback-triggered serial traffic that continue, even though loop() is no longer running.
All of the above behavior occurs for all tested commits beginning with 6cc156c. If I use 7e71bef or anything prior, the issues above do not arise.
Let me know if there's anything I can do to help troubleshoot this.
Thx.
Activity
zackees commentedon Sep 19, 2025
looking into this now.
fixes FastLED#2084, reverts worker pools for rmt
ci(fbuild): require fbuild 2.5.52, drop the LPC8xx core pin, retry on…