Skip to content

fix(esp32): disable unsupported C2 RMT backend - #3229

Merged
zackees merged 1 commit into
masterfrom
feat/fix-esp32c2-rmt5-header
Jun 18, 2026
Merged

zackees merged 1 commit into
masterfrom
feat/fix-esp32c2-rmt5-header

Conversation

@zackees

@zackees zackees commented Jun 18, 2026 •

Copy link
Copy Markdown
Member

Summary

  • disable FastLED's RMT/RMT5 backend for ESP32-C2 because the C2 IDF package does not expose the direct \soc/rmt_struct.h\ register header used by the backend
  • force \FASTLED_RMT5\ off for C2 even when the esp32c2 PlatformIO env passes \-DFASTLED_RMT5=1\, allowing the existing clockless-SPI path to compile

Fixes failing job: https://github.com/FastLED/FastLED/actions/runs/27759522985/job/82129954144

Tests

  • \.venv\Scripts\python.exe ci\ci-compile.py --no-interactive --no-parallel --max-failures 1 esp32c2 AnalogOutput\ (passes; build metadata generation later reported a non-fatal 900s timeout)
  • \git diff --check\`n- \.venv\Scripts\python.exe -m pytest ci\tests -q\ (timed out after 120s)

Summary by CodeRabbit

  • Bug Fixes
    • Improved RMT capability detection and configuration for ESP32-C2 hardware variant to ensure proper functionality and prevent initialization errors on this device model.

@coderabbitai

coderabbitai Bot commented Jun 18, 2026 •

Copy link
Copy Markdown

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: f622cbf3-5345-4d83-a4a5-65c423e06860

📥 Commits

Reviewing files that changed from the base of the PR and between 447bd1d and 91f4044.

📒 Files selected for processing (1)
  • src/platforms/esp/32/feature_flags/enabled.h

📝 Walkthrough

Walkthrough

Two macro definitions in the ESP32 feature flags header are updated to special-case the ESP32-C2 chip. FASTLED_ESP32_HAS_RMT is forced to 0 on FL_IS_ESP_32C2 instead of inheriting SOC_RMT_SUPPORTED, and FASTLED_RMT5 is explicitly undefined then set to 0 on that platform before the general detection logic runs.

Changes

ESP32-C2 RMT flag overrides

Layer / File(s) Summary
ESP32-C2 RMT and RMT5 macro overrides
src/platforms/esp/32/feature_flags/enabled.h
FASTLED_ESP32_HAS_RMT is forced to 0 for FL_IS_ESP_32C2 (lines 96–102); FASTLED_RMT5 has any prior definition cleared via #undef then set to 0 for FL_IS_ESP_32C2 before the general detection logic (lines 116–120).

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~3 minutes

Possibly related issues

Possibly related PRs

  • FastLED/FastLED#2635: Adds a GpioIsrRx::create() no-op stub path that is exercised when FASTLED_RMT5=0, the value this PR unconditionally sets on ESP32-C2.

Poem

🐇 Hoppity-hop through the chip tree,
The C2 says "RMT? Not for me!"
A zero here, an undef there,
No stray RMT flags floating in air.
The rabbit stamps the flag with glee! ✅

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title accurately and concisely summarizes the main change: disabling RMT backend support for ESP32-C2 due to incompatibility, which is the core purpose of the changeset.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch feat/fix-esp32c2-rmt5-header

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.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@fastled-project-sync fastled-project-sync Bot moved this to Triage in FastLED Tracker Jun 18, 2026
@zackees
zackees merged commit f787011 into master Jun 18, 2026
10 checks passed
@zackees
zackees deleted the feat/fix-esp32c2-rmt5-header branch June 18, 2026 20:46
@fastled-project-sync fastled-project-sync Bot moved this from Triage to Done in FastLED Tracker Jun 18, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

1 participant