Skip to content

Set ESP-IDF as default framework#112

Merged
edwardtfn merged 52 commits intomainfrom
idf-as-default
Aug 1, 2025
Merged

Set ESP-IDF as default framework#112
edwardtfn merged 52 commits intomainfrom
idf-as-default

Conversation

@edwardtfn
Copy link
Owner

@edwardtfn edwardtfn commented Jul 14, 2025

Summary by CodeRabbit

  • New Features

    • Updated documentation to announce migration to the ESP-IDF framework, with guidance for new and existing users.
    • Enhanced speaker hardware support with improved configuration options and stereo output.
  • Bug Fixes

    • Replaced manual C++ event handling for touch actions with native ESPHome event actions for better integration.
  • Refactor

    • Migrated LED strip configuration to a new platform for improved performance and reliability.
    • Updated media player configuration to use the new speaker platform with persistent volume memory and enhanced audio routing.
    • Streamlined Bluetooth Proxy support by removing deprecated BLE proxy packages and updating configuration instructions.
    • Corrected plural suffix string usage in logging for buttons and relays to fix string handling errors.
  • Chores

    • Removed deprecated and redundant YAML configuration files and test manifests.
    • Overhauled CI workflows for more comprehensive validation, multi-framework support, and clearer build summaries.
    • Removed legacy media player add-on and BLE proxy packages; added compile-time error guidance for removed packages.

@coderabbitai
Copy link
Contributor

coderabbitai bot commented Jul 14, 2025

Walkthrough

This change set removes the BLE proxy and media player add-on YAML packages, deletes the core hardware media player configuration, and updates other YAML files to use the ESPHome native bluetooth_proxy component directly. It migrates LED and speaker configurations to new platforms and formats, updates documentation for ESP-IDF framework migration, and restructures CI workflows for improved framework and feature coverage.

Changes

Cohort / File(s) Change Summary
BLE Proxy Package Removal & Migration
ESPHome/TX-Ultimate-Easy-ESPHome_addon_ble_proxy.yaml, .test/esphome_ard_ble_proxy.yaml, .test/esphome_idf_ble_proxy.yaml
Removes BLE proxy add-on package, replaces with a compile-time error and directs users to use bluetooth_proxy: directly; test configs updated to use native bluetooth_proxy.
Media Player Add-on & Core Media Deletion
ESPHome/TX-Ultimate-Easy-ESPHome_addon_media_player.yaml, ESPHome/TX-Ultimate-Easy-ESPHome_core_hw_media_player.yaml, .test/esphome_ard_media_player.yaml
Removes the media player add-on and core hardware media player configurations, including all related entities and package inclusions.
Media Player Refactor & Persistent Volume
ESPHome/TX-Ultimate-Easy-ESPHome_standard_media_player.yaml
Refactors media player to use the speaker platform, adds persistent volume management, updates scripts, and removes amplifier switch.
LED Platform Migration
ESPHome/TX-Ultimate-Easy-ESPHome_core_hw_leds.yaml, .test/common_idf.yaml
Migrates LED configuration from neopixelbus to esp32_rmt_led_strip; removes test light config.
Speaker & Audio Hardware Updates
ESPHome/TX-Ultimate-Easy-ESPHome_standard_hw_speaker.yaml, ESPHome/TX-Ultimate-Easy-ESPHome_standard_hw_audio.yaml
Updates speaker build flags and configuration, adds new audio switch, changes audio channel and parameters.
Touch Event Handling Modernization
ESPHome/TX-Ultimate-Easy-ESPHome_core_hw_touch.yaml
Replaces manual C++ event firing with native ESPHome homeassistant.event actions for touch events.
ESP-IDF Framework Adoption
ESPHome/TX-Ultimate-Easy-ESPHome_core_common.yaml, README.md
Explicitly sets ESP-IDF as the framework for ESP32, updates documentation for framework migration and Bluetooth proxy support.
CI Workflow Overhaul
.github/workflows/validate_esphome.yml, .github/workflows/validate_esphome_beta.yml
Replaces beta validation workflow, restructures main CI to add framework-specific jobs, summary aggregation, and new triggers.
Test & Config Cleanups
.test/common_idf53.yaml, .test/esphome_idf_basic.yaml
Removes outdated test configs and deletes media player and switch from IDF basic test YAML.
Plural Suffix Refactor in Logs
ESPHome/TX-Ultimate-Easy-ESPHome_core_common.yaml, ESPHome/TX-Ultimate-Easy-ESPHome_core_hw_buttons.yaml, ESPHome/TX-Ultimate-Easy-ESPHome_core_hw_relays.yaml, ESPHome/TX-Ultimate-Easy-ESPHome_core_hw_leds.yaml
Removes global plural suffix variable, replaces with local inline or lambda variables for pluralization in logging.

Sequence Diagram(s)

Bluetooth Proxy Configuration Flow (Old vs. New)

Old (With Add-on Package):

sequenceDiagram
    participant User
    participant ESPHome
    participant Addon_BLE_Proxy_Package

    User->>ESPHome: Includes addon_ble_proxy package in YAML
    ESPHome->>Addon_BLE_Proxy_Package: Loads and configures BLE proxy components
    Addon_BLE_Proxy_Package-->>ESPHome: Provides BLE proxy functionality
Loading

New (Direct Native Integration):

sequenceDiagram
    participant User
    participant ESPHome

    User->>ESPHome: Adds bluetooth_proxy: directly in YAML
    ESPHome-->>User: Configures native Bluetooth proxy component
Loading

Media Player Volume Persistence

sequenceDiagram
    participant ESPHome
    participant MediaPlayer
    participant PersistentStorage

    ESPHome->>PersistentStorage: Retrieve persistent_media_player_volume at boot
    ESPHome->>MediaPlayer: Set volume to persisted value
    MediaPlayer->>ESPHome: On volume change
    ESPHome->>PersistentStorage: Update persistent_media_player_volume
Loading

Estimated code review effort

🎯 4 (Complex) | ⏱️ ~40 minutes

Possibly related PRs

Note

⚡️ Unit Test Generation is now available in beta!

Learn more here, or try it out under "Finishing Touches" below.


📜 Recent review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 0a95a7f and 526b257.

📒 Files selected for processing (1)
  • .github/workflows/validate_esphome.yml (2 hunks)
🧰 Additional context used
🧠 Learnings (14)
📓 Common learnings
Learnt from: edwardtfn
PR: edwardtfn/TX-Ultimate-Easy#112
File: .github/workflows/validate_esphome_dev.yml:52-210
Timestamp: 2025-07-29T08:10:32.072Z
Learning: Media player functionality is now supported by both Arduino and IDF frameworks in TX Ultimate Easy ESPHome configurations, removing the previous Arduino-only limitation.
Learnt from: edwardtfn
PR: edwardtfn/TX-Ultimate-Easy#71
File: ESPHome/TX-Ultimate-Easy-ESPHome_core_hw_speaker.yaml:20-21
Timestamp: 2024-12-24T22:40:00.309Z
Learning: The BLE addon uses a unique speaker component named mp_speaker and removes the media_player component entirely, so no rename from mp_speaker to mp_media_player is required there.
Learnt from: edwardtfn
PR: edwardtfn/TX-Ultimate-Easy#73
File: ESPHome/TX-Ultimate-Easy-ESPHome_addon_media_player.yaml:14-20
Timestamp: 2024-12-26T21:18:44.593Z
Learning: In the TX Ultimate Easy ESPHome setup, the i2s_dout_pin for audio output is defined in respective speaker or media_player components rather than in the core_hw_audio package.
📚 Learning: applies to *.{yaml,yml,.yamllint} : comments in yaml files should be present and properly formatted ...
Learnt from: CR
PR: edwardtfn/TX-Ultimate-Easy#0
File: .rules/yamllint.yml:0-0
Timestamp: 2025-07-29T12:55:24.801Z
Learning: Applies to *.{yaml,yml,.yamllint} : Comments in YAML files should be present and properly formatted (comments: level: warning)

Applied to files:

  • .github/workflows/validate_esphome.yml
📚 Learning: applies to *.{yaml,yml,.yamllint} : hyphens must be used correctly in yaml files (hyphens: enable)...
Learnt from: CR
PR: edwardtfn/TX-Ultimate-Easy#0
File: .rules/yamllint.yml:0-0
Timestamp: 2025-07-29T12:55:24.801Z
Learning: Applies to *.{yaml,yml,.yamllint} : Hyphens must be used correctly in YAML files (hyphens: enable)

Applied to files:

  • .github/workflows/validate_esphome.yml
📚 Learning: applies to *.{yaml,yml,.yamllint} : truthy values in yaml files should be checked (truthy: level: wa...
Learnt from: CR
PR: edwardtfn/TX-Ultimate-Easy#0
File: .rules/yamllint.yml:0-0
Timestamp: 2025-07-29T12:55:24.801Z
Learning: Applies to *.{yaml,yml,.yamllint} : Truthy values in YAML files should be checked (truthy: level: warning)

Applied to files:

  • .github/workflows/validate_esphome.yml
📚 Learning: applies to *.{yaml,yml,.yamllint} : comments in yaml files should be properly indented (comments-ind...
Learnt from: CR
PR: edwardtfn/TX-Ultimate-Easy#0
File: .rules/yamllint.yml:0-0
Timestamp: 2025-07-29T12:55:24.801Z
Learning: Applies to *.{yaml,yml,.yamllint} : Comments in YAML files should be properly indented (comments-indentation: level: warning)

Applied to files:

  • .github/workflows/validate_esphome.yml
📚 Learning: applies to *.{yaml,yml,.yamllint} : yaml files should have a document end marker (document-end: leve...
Learnt from: CR
PR: edwardtfn/TX-Ultimate-Easy#0
File: .rules/yamllint.yml:0-0
Timestamp: 2025-07-29T12:55:24.801Z
Learning: Applies to *.{yaml,yml,.yamllint} : YAML files should have a document end marker (document-end: level: warning)

Applied to files:

  • .github/workflows/validate_esphome.yml
📚 Learning: applies to *.{yaml,yml,.yamllint} : yaml files should have a document start marker (document-start: ...
Learnt from: CR
PR: edwardtfn/TX-Ultimate-Easy#0
File: .rules/yamllint.yml:0-0
Timestamp: 2025-07-29T12:55:24.801Z
Learning: Applies to *.{yaml,yml,.yamllint} : YAML files should have a document start marker (document-start: level: warning)

Applied to files:

  • .github/workflows/validate_esphome.yml
📚 Learning: applies to *.{yaml,yml,.yamllint} : indentation must be correct in yaml files (indentation: enable)...
Learnt from: CR
PR: edwardtfn/TX-Ultimate-Easy#0
File: .rules/yamllint.yml:0-0
Timestamp: 2025-07-29T12:55:24.801Z
Learning: Applies to *.{yaml,yml,.yamllint} : Indentation must be correct in YAML files (indentation: enable)

Applied to files:

  • .github/workflows/validate_esphome.yml
📚 Learning: applies to *.{yaml,yml,.yamllint} : octal values in yaml files should be checked (octal-values: leve...
Learnt from: CR
PR: edwardtfn/TX-Ultimate-Easy#0
File: .rules/yamllint.yml:0-0
Timestamp: 2025-07-29T12:55:24.801Z
Learning: Applies to *.{yaml,yml,.yamllint} : Octal values in YAML files should be checked (octal-values: level: warning)

Applied to files:

  • .github/workflows/validate_esphome.yml
📚 Learning: applies to *.{yaml,yml,.yamllint} : trailing spaces are not allowed in yaml files (trailing-spaces: ...
Learnt from: CR
PR: edwardtfn/TX-Ultimate-Easy#0
File: .rules/yamllint.yml:0-0
Timestamp: 2025-07-29T12:55:24.801Z
Learning: Applies to *.{yaml,yml,.yamllint} : Trailing spaces are not allowed in YAML files (trailing-spaces: enable)

Applied to files:

  • .github/workflows/validate_esphome.yml
📚 Learning: applies to *.{yaml,yml,.yamllint} : braces must be used correctly in yaml files (braces: enable)...
Learnt from: CR
PR: edwardtfn/TX-Ultimate-Easy#0
File: .rules/yamllint.yml:0-0
Timestamp: 2025-07-29T12:55:24.801Z
Learning: Applies to *.{yaml,yml,.yamllint} : Braces must be used correctly in YAML files (braces: enable)

Applied to files:

  • .github/workflows/validate_esphome.yml
📚 Learning: applies to *.{yaml,yml,.yamllint} : yaml files must end with a new line (new-line-at-end-of-file: en...
Learnt from: CR
PR: edwardtfn/TX-Ultimate-Easy#0
File: .rules/yamllint.yml:0-0
Timestamp: 2025-07-29T12:55:24.801Z
Learning: Applies to *.{yaml,yml,.yamllint} : YAML files must end with a new line (new-line-at-end-of-file: enable)

Applied to files:

  • .github/workflows/validate_esphome.yml
📚 Learning: applies to *.{yaml,yml,.yamllint} : empty lines are enabled in yaml files (empty-lines: enable)...
Learnt from: CR
PR: edwardtfn/TX-Ultimate-Easy#0
File: .rules/yamllint.yml:0-0
Timestamp: 2025-07-29T12:55:24.801Z
Learning: Applies to *.{yaml,yml,.yamllint} : Empty lines are enabled in YAML files (empty-lines: enable)

Applied to files:

  • .github/workflows/validate_esphome.yml
📚 Learning: the user clarified that the proposed yaml anchor refactoring approach will not work with esphome, an...
Learnt from: edwardtfn
PR: edwardtfn/TX-Ultimate-Easy#56
File: ESPHome/TX-Ultimate-Easy-ESPHome_core_hw_touch.yaml:18-147
Timestamp: 2024-12-23T03:35:56.090Z
Learning: The user clarified that the proposed YAML anchor refactoring approach will not work with ESPHome, and they intend to maintain the current implementation despite code duplication.

Applied to files:

  • .github/workflows/validate_esphome.yml
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (4)
  • GitHub Check: 🏗️ IDF Core (latest)
  • GitHub Check: 🏗️ Arduino Core (latest)
  • GitHub Check: 🏗️ IDF Core (latest)
  • GitHub Check: 🏗️ Arduino Core (latest)
✨ Finishing Touches
🧪 Generate unit tests
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch idf-as-default

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
🪧 Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>, please review it.
    • Explain this complex logic.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    • @coderabbitai explain this code block.
    • @coderabbitai modularize this function.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @coderabbitai read src/utils.ts and explain its main purpose.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.
    • @coderabbitai help me debug CodeRabbit configuration file.

Support

Need help? Create a ticket on our support page for assistance with any issues or questions.

Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

CodeRabbit Commands (Invoked using PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai full review to do a full review from scratch and review all the files again.
  • @coderabbitai summary to regenerate the summary of the PR.
  • @coderabbitai generate docstrings to generate docstrings for this PR.
  • @coderabbitai generate sequence diagram to generate a sequence diagram of the changes in this PR.
  • @coderabbitai generate unit tests to generate unit tests for this PR.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

Other keywords and placeholders

  • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai anywhere in the PR title to generate the title automatically.

CodeRabbit Configuration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • Please see the configuration documentation for more information.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

Documentation and Community

  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🧹 Nitpick comments (1)
ESPHome/TX-Ultimate-Easy-ESPHome_core_hw_leds.yaml (1)

58-60: Remove leftover neopixelbus comments

The commented-out legacy configuration adds noise and can mislead future readers.
Clean them up or move them to the commit message/changelog.

📜 Review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between ffdb3a2 and daaffdb.

📒 Files selected for processing (3)
  • ESPHome/TX-Ultimate-Easy-ESPHome_addon_ble_proxy.yaml (0 hunks)
  • ESPHome/TX-Ultimate-Easy-ESPHome_core_common.yaml (1 hunks)
  • ESPHome/TX-Ultimate-Easy-ESPHome_core_hw_leds.yaml (1 hunks)
💤 Files with no reviewable changes (1)
  • ESPHome/TX-Ultimate-Easy-ESPHome_addon_ble_proxy.yaml
🧰 Additional context used
🧠 Learnings (2)
📓 Common learnings
Learnt from: edwardtfn
PR: edwardtfn/TX-Ultimate-Easy#71
File: ESPHome/TX-Ultimate-Easy-ESPHome_core_hw_speaker.yaml:20-21
Timestamp: 2024-12-24T22:40:00.309Z
Learning: The BLE addon uses a unique speaker component named mp_speaker and removes the media_player component entirely, so no rename from mp_speaker to mp_media_player is required there.
Learnt from: edwardtfn
PR: edwardtfn/TX-Ultimate-Easy#73
File: ESPHome/TX-Ultimate-Easy-ESPHome_addon_media_player.yaml:14-20
Timestamp: 2024-12-26T21:18:44.593Z
Learning: In the TX Ultimate Easy ESPHome setup, the i2s_dout_pin for audio output is defined in respective speaker or media_player components rather than in the core_hw_audio package.
Learnt from: edwardtfn
PR: edwardtfn/TX-Ultimate-Easy#56
File: ESPHome/TX-Ultimate-Easy-ESPHome_core_hw_touch.yaml:18-147
Timestamp: 2024-12-23T03:35:56.090Z
Learning: The user clarified that the proposed YAML anchor refactoring approach will not work with ESPHome, and they intend to maintain the current implementation despite code duplication.
ESPHome/TX-Ultimate-Easy-ESPHome_core_common.yaml (1)
Learnt from: edwardtfn
PR: edwardtfn/TX-Ultimate-Easy#73
File: ESPHome/TX-Ultimate-Easy-ESPHome_addon_media_player.yaml:14-20
Timestamp: 2024-12-26T21:18:44.593Z
Learning: In the TX Ultimate Easy ESPHome setup, the i2s_dout_pin for audio output is defined in respective speaker or media_player components rather than in the core_hw_audio package.
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (6)
  • GitHub Check: Core (IDF)
  • GitHub Check: Core (Arduino)
  • GitHub Check: Core (Arduino)
  • GitHub Check: Core (IDF)
  • GitHub Check: Analyze (python)
  • GitHub Check: Analyze (actions)
🔇 Additional comments (1)
ESPHome/TX-Ultimate-Easy-ESPHome_core_common.yaml (1)

63-68: Explicitly pin the ESP-IDF version for reproducible builds

Great move switching to ESP-IDF, but the toolchain bundled by ESPHome occasionally bumps minor SDK versions that introduce breaking changes.
Locking the version (or using version: recommended) keeps CI/OTA builds stable.

   framework:
     type: esp-idf
+    # Prevent silent SDK upgrades
+    version: recommended     # or a concrete tag such as "5.1.2"

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 0

🧹 Nitpick comments (1)
ESPHome/TX-Ultimate-Easy-ESPHome_standard_media_player.yaml (1)

48-61: Mixer/resampler chain works, but consider trimming the extra resampler hop

The current graph is
media_player → resampler → embedded speaker → mixer → final speaker.
Unless you really need sample-rate conversion, the two resampler instances add RAM and CPU overhead on ESP-IDF builds. If your sources are already at the target rate (usually 48 kHz in ESPHome), you can point the pipelines straight at announcement_speaker_embedded / media_speaker_embedded and drop the resamplers entirely.

This keeps latency & memory lower:

-  - platform: resampler
-    id: announcement_spk_resampling_input
-    output_speaker: announcement_speaker_embedded
+  # Resampler removed – pipeline can feed the embedded speaker directly

-  - platform: resampler
-    id: media_spk_resampling_input
-    output_speaker: media_speaker_embedded
+  # Same here

Optional, but worth the cleanup if SRC is not required.

📜 Review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 0a3ceb9 and 680042a.

📒 Files selected for processing (1)
  • ESPHome/TX-Ultimate-Easy-ESPHome_standard_media_player.yaml (2 hunks)
🧰 Additional context used
🧠 Learnings (2)
📓 Common learnings
Learnt from: edwardtfn
PR: edwardtfn/TX-Ultimate-Easy#71
File: ESPHome/TX-Ultimate-Easy-ESPHome_core_hw_speaker.yaml:20-21
Timestamp: 2024-12-24T22:40:00.309Z
Learning: The BLE addon uses a unique speaker component named mp_speaker and removes the media_player component entirely, so no rename from mp_speaker to mp_media_player is required there.
Learnt from: edwardtfn
PR: edwardtfn/TX-Ultimate-Easy#73
File: ESPHome/TX-Ultimate-Easy-ESPHome_addon_media_player.yaml:14-20
Timestamp: 2024-12-26T21:18:44.593Z
Learning: In the TX Ultimate Easy ESPHome setup, the i2s_dout_pin for audio output is defined in respective speaker or media_player components rather than in the core_hw_audio package.
Learnt from: edwardtfn
PR: edwardtfn/TX-Ultimate-Easy#56
File: ESPHome/TX-Ultimate-Easy-ESPHome_core_hw_touch.yaml:18-147
Timestamp: 2024-12-23T03:35:56.090Z
Learning: The user clarified that the proposed YAML anchor refactoring approach will not work with ESPHome, and they intend to maintain the current implementation despite code duplication.
ESPHome/TX-Ultimate-Easy-ESPHome_standard_media_player.yaml (2)

Learnt from: edwardtfn
PR: #73
File: ESPHome/TX-Ultimate-Easy-ESPHome_addon_media_player.yaml:14-20
Timestamp: 2024-12-26T21:18:44.593Z
Learning: In the TX Ultimate Easy ESPHome setup, the i2s_dout_pin for audio output is defined in respective speaker or media_player components rather than in the core_hw_audio package.

Learnt from: edwardtfn
PR: #71
File: ESPHome/TX-Ultimate-Easy-ESPHome_core_hw_speaker.yaml:20-21
Timestamp: 2024-12-24T22:40:00.309Z
Learning: The BLE addon uses a unique speaker component named mp_speaker and removes the media_player component entirely, so no rename from mp_speaker to mp_media_player is required there.

⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (4)
  • GitHub Check: Core (IDF)
  • GitHub Check: Core (Arduino)
  • GitHub Check: Core (Arduino)
  • GitHub Check: Core (IDF)
🔇 Additional comments (1)
ESPHome/TX-Ultimate-Easy-ESPHome_standard_media_player.yaml (1)

26-30: Verify that every speaker ID in the pipelines is actually resolvable at compile-time

announcement_pipeline.speaker and media_pipeline.speaker reference announcement_spk_ressampling_input and media_spk_resampling_input, which are defined further below – good.
However, those resamplers in turn output to announcement_speaker_embedded and media_speaker_embedded, and the mixer expects a speaker_embedded output. None of those IDs are declared in this file; they must be supplied by standard_hw_audio.yaml. A missing ID will make the whole build fail with “Cannot find speaker id …”.

Please double-check that all three downstream IDs (speaker_embedded, announcement_speaker_embedded, media_speaker_embedded) exist in the included package or add stubs here.

This kind of solves #9

Replace TX-Ultimate-Easy-ESPHome_addon_ble_proxy.yaml with compilation
error to force migration to direct bluetooth_proxy configuration.

BREAKING CHANGE: Configurations including this package will fail to
compile. Users must remove the package reference and add bluetooth_proxy
directly to their YAML.

Before:
  packages:
    addon_bluetooth_proxy: !include TX-Ultimate-Easy-ESPHome_addon_ble_proxy.yaml

After:
  bluetooth_proxy:
@edwardtfn edwardtfn linked an issue Jul 29, 2025 that may be closed by this pull request
Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 3

🧹 Nitpick comments (1)
.github/workflows/validate_esphome_dev.yml (1)

49-50: Hard-coded path to lint rules may break external forks

./.rules/yamllint.yml assumes every fork contains this private directory.
Consider falling back to the default rules when the file is missing to keep community contributions friction-free.

📜 Review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 36b28a2 and 644ba8e.

📒 Files selected for processing (1)
  • .github/workflows/validate_esphome_dev.yml (1 hunks)
🧰 Additional context used
🧠 Learnings (1)
📓 Common learnings
Learnt from: edwardtfn
PR: edwardtfn/TX-Ultimate-Easy#71
File: ESPHome/TX-Ultimate-Easy-ESPHome_core_hw_speaker.yaml:20-21
Timestamp: 2024-12-24T22:40:00.309Z
Learning: The BLE addon uses a unique speaker component named mp_speaker and removes the media_player component entirely, so no rename from mp_speaker to mp_media_player is required there.
Learnt from: edwardtfn
PR: edwardtfn/TX-Ultimate-Easy#56
File: ESPHome/TX-Ultimate-Easy-ESPHome_core_hw_touch.yaml:18-147
Timestamp: 2024-12-23T03:35:56.090Z
Learning: The user clarified that the proposed YAML anchor refactoring approach will not work with ESPHome, and they intend to maintain the current implementation despite code duplication.
Learnt from: edwardtfn
PR: edwardtfn/TX-Ultimate-Easy#73
File: ESPHome/TX-Ultimate-Easy-ESPHome_addon_media_player.yaml:14-20
Timestamp: 2024-12-26T21:18:44.593Z
Learning: In the TX Ultimate Easy ESPHome setup, the i2s_dout_pin for audio output is defined in respective speaker or media_player components rather than in the core_hw_audio package.
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (8)
  • GitHub Check: Core (Arduino)
  • GitHub Check: Core (IDF)
  • GitHub Check: Core (Arduino)
  • GitHub Check: Core (IDF)
  • GitHub Check: Core (Arduino)
  • GitHub Check: Core (IDF)
  • GitHub Check: Core (Arduino)
  • GitHub Check: Core (IDF)

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 3

🧹 Nitpick comments (1)
README.md (1)

66-68: Consider trimming wording for clarity

“In succession” is slightly verbose; “twice” conveys the same meaning.
Example:

-Flash twice in succession to ensure both firmware partitions ...
+Flash twice to ensure both firmware partitions ...
📜 Review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 644ba8e and 7e07061.

📒 Files selected for processing (3)
  • ESPHome/TX-Ultimate-Easy-ESPHome_core_hw_touch.yaml (2 hunks)
  • ESPHome/TX-Ultimate-Easy-ESPHome_standard_media_player.yaml (3 hunks)
  • README.md (2 hunks)
🚧 Files skipped from review as they are similar to previous changes (1)
  • ESPHome/TX-Ultimate-Easy-ESPHome_standard_media_player.yaml
🧰 Additional context used
🧠 Learnings (3)
📓 Common learnings
Learnt from: edwardtfn
PR: edwardtfn/TX-Ultimate-Easy#71
File: ESPHome/TX-Ultimate-Easy-ESPHome_core_hw_speaker.yaml:20-21
Timestamp: 2024-12-24T22:40:00.309Z
Learning: The BLE addon uses a unique speaker component named mp_speaker and removes the media_player component entirely, so no rename from mp_speaker to mp_media_player is required there.
Learnt from: edwardtfn
PR: edwardtfn/TX-Ultimate-Easy#56
File: ESPHome/TX-Ultimate-Easy-ESPHome_core_hw_touch.yaml:18-147
Timestamp: 2024-12-23T03:35:56.090Z
Learning: The user clarified that the proposed YAML anchor refactoring approach will not work with ESPHome, and they intend to maintain the current implementation despite code duplication.
Learnt from: edwardtfn
PR: edwardtfn/TX-Ultimate-Easy#73
File: ESPHome/TX-Ultimate-Easy-ESPHome_addon_media_player.yaml:14-20
Timestamp: 2024-12-26T21:18:44.593Z
Learning: In the TX Ultimate Easy ESPHome setup, the i2s_dout_pin for audio output is defined in respective speaker or media_player components rather than in the core_hw_audio package.
README.md (1)

Learnt from: edwardtfn
PR: #73
File: ESPHome/TX-Ultimate-Easy-ESPHome_addon_media_player.yaml:14-20
Timestamp: 2024-12-26T21:18:44.593Z
Learning: In the TX Ultimate Easy ESPHome setup, the i2s_dout_pin for audio output is defined in respective speaker or media_player components rather than in the core_hw_audio package.

ESPHome/TX-Ultimate-Easy-ESPHome_core_hw_touch.yaml (1)

Learnt from: edwardtfn
PR: #111
File: ESPHome/TX-Ultimate-Easy-ESPHome_core_common.yaml:121-129
Timestamp: 2025-07-09T22:37:04.600Z
Learning: In ESPHome, to fire Home Assistant events from C++ lambda functions, the correct approach is to create a stack variable of type esphome::api::CustomAPIDevice and call fire_homeassistant_event() on it, not to use the API server component directly.

🪛 LanguageTool
README.md

[style] ~67-~67: ‘in succession’ might be wordy. Consider a shorter alternative.
Context: ...e may not update correctly. Flash twice in succession to ensure both firmware partitions cont...

(EN_WORDINESS_PREMIUM_IN_SUCCESSION)

🪛 GitHub Check: Code scan (YAML)
ESPHome/TX-Ultimate-Easy-ESPHome_core_hw_touch.yaml

[failure] 428-428:
428:105 syntax error: mapping values are not allowed here (syntax)

🪛 GitHub Actions: Validate ESPHome (Dev)
ESPHome/TX-Ultimate-Easy-ESPHome_core_hw_touch.yaml

[error] 428-428: Syntax error: mapping values are not allowed here (syntax) at line 428, column 105.

🪛 GitHub Actions: Validate ESPHome (Beta)
ESPHome/TX-Ultimate-Easy-ESPHome_core_hw_touch.yaml

[error] 428-428: Syntax error: mapping values are not allowed here (syntax) at line 428, column 105.

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🧹 Nitpick comments (2)
.github/workflows/validate_esphome.yml (2)

8-10: CI only runs on manual trigger – is that intentional?

on: workflow_dispatch means validation never runs for normal push / pull_request events.
Given this file replaces the older automatic validation workflows, accidental omissions may slip through.

If you still want automatic coverage, consider:

on:
  pull_request:
    branches: [ "**" ]
  push:
    branches: [ main ]
  workflow_dispatch:

42-47: Minor: pin build-action version

Using esphome/build-action@v4 without a commit SHA risks pulling a breaking change.
Pin to a full ref or tag with a hash for reproducible builds.

- uses: esphome/build-action@v4
+ uses: esphome/build-action@v4.0.0   # or @v4@<commit-sha>
📜 Review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 70a0546 and f9da912.

📒 Files selected for processing (4)
  • .github/workflows/validate_esphome.yml (2 hunks)
  • .github/workflows/validate_esphome_beta.yml (0 hunks)
  • .test/esphome_idf_media_player.yaml (1 hunks)
  • ESPHome/TX-Ultimate-Easy-ESPHome_standard_hw_speaker.yaml (1 hunks)
💤 Files with no reviewable changes (1)
  • .github/workflows/validate_esphome_beta.yml
✅ Files skipped from review due to trivial changes (1)
  • .test/esphome_idf_media_player.yaml
🧰 Additional context used
🧠 Learnings (2)
📓 Common learnings
Learnt from: edwardtfn
PR: edwardtfn/TX-Ultimate-Easy#112
File: .github/workflows/validate_esphome_dev.yml:52-210
Timestamp: 2025-07-29T08:10:31.975Z
Learning: Media player functionality is now supported by both Arduino and IDF frameworks in TX Ultimate Easy ESPHome configurations, removing the previous Arduino-only limitation.
Learnt from: edwardtfn
PR: edwardtfn/TX-Ultimate-Easy#73
File: ESPHome/TX-Ultimate-Easy-ESPHome_addon_media_player.yaml:14-20
Timestamp: 2024-12-26T21:18:44.593Z
Learning: In the TX Ultimate Easy ESPHome setup, the i2s_dout_pin for audio output is defined in respective speaker or media_player components rather than in the core_hw_audio package.
Learnt from: edwardtfn
PR: edwardtfn/TX-Ultimate-Easy#71
File: ESPHome/TX-Ultimate-Easy-ESPHome_core_hw_speaker.yaml:20-21
Timestamp: 2024-12-24T22:40:00.309Z
Learning: The BLE addon uses a unique speaker component named mp_speaker and removes the media_player component entirely, so no rename from mp_speaker to mp_media_player is required there.
Learnt from: edwardtfn
PR: edwardtfn/TX-Ultimate-Easy#56
File: ESPHome/TX-Ultimate-Easy-ESPHome_core_hw_touch.yaml:18-147
Timestamp: 2024-12-23T03:35:56.090Z
Learning: The user clarified that the proposed YAML anchor refactoring approach will not work with ESPHome, and they intend to maintain the current implementation despite code duplication.
ESPHome/TX-Ultimate-Easy-ESPHome_standard_hw_speaker.yaml (3)

Learnt from: edwardtfn
PR: #73
File: ESPHome/TX-Ultimate-Easy-ESPHome_addon_media_player.yaml:14-20
Timestamp: 2024-12-26T21:18:44.593Z
Learning: In the TX Ultimate Easy ESPHome setup, the i2s_dout_pin for audio output is defined in respective speaker or media_player components rather than in the core_hw_audio package.

Learnt from: edwardtfn
PR: #112
File: .github/workflows/validate_esphome_dev.yml:52-210
Timestamp: 2025-07-29T08:10:31.975Z
Learning: Media player functionality is now supported by both Arduino and IDF frameworks in TX Ultimate Easy ESPHome configurations, removing the previous Arduino-only limitation.

Learnt from: edwardtfn
PR: #71
File: ESPHome/TX-Ultimate-Easy-ESPHome_core_hw_speaker.yaml:20-21
Timestamp: 2024-12-24T22:40:00.309Z
Learning: The BLE addon uses a unique speaker component named mp_speaker and removes the media_player component entirely, so no rename from mp_speaker to mp_media_player is required there.

🔇 Additional comments (1)
.github/workflows/validate_esphome.yml (1)

31-41: No missing test YAMLs in .test directory

I’ve verified that for every framework (ard, idf) × target (core, basic, hw_relays, hw_speaker, hw_vibration, ble_proxy, media_player) combination there is a corresponding .test/esphome_<framework>_<target>.yaml file. There are no orphan entries and the matrix can remain unchanged.

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 4

🧹 Nitpick comments (1)
.github/workflows/validate_esphome.yml (1)

55-57: Pin critical marketplace actions to stable versions

actions/checkout@main and actions/setup-python@main track a moving branch, opening you up to breaking changes or supply-chain attacks. Pin to the latest major tags (or SHA) instead.

-        uses: actions/checkout@main
+        uses: actions/checkout@v4           # or a commit SHA

-        uses: actions/setup-python@main
+        uses: actions/setup-python@v5       # or a commit SHA
📜 Review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between f9da912 and 78d820d.

📒 Files selected for processing (2)
  • .github/workflows/validate_esphome.yml (2 hunks)
  • .test/esphome_idf_ble_proxy.yaml (1 hunks)
✅ Files skipped from review due to trivial changes (1)
  • .test/esphome_idf_ble_proxy.yaml
🧰 Additional context used
🧠 Learnings (1)
📓 Common learnings
Learnt from: edwardtfn
PR: edwardtfn/TX-Ultimate-Easy#112
File: .github/workflows/validate_esphome_dev.yml:52-210
Timestamp: 2025-07-29T08:10:31.975Z
Learning: Media player functionality is now supported by both Arduino and IDF frameworks in TX Ultimate Easy ESPHome configurations, removing the previous Arduino-only limitation.
Learnt from: edwardtfn
PR: edwardtfn/TX-Ultimate-Easy#73
File: ESPHome/TX-Ultimate-Easy-ESPHome_addon_media_player.yaml:14-20
Timestamp: 2024-12-26T21:18:44.593Z
Learning: In the TX Ultimate Easy ESPHome setup, the i2s_dout_pin for audio output is defined in respective speaker or media_player components rather than in the core_hw_audio package.
Learnt from: edwardtfn
PR: edwardtfn/TX-Ultimate-Easy#71
File: ESPHome/TX-Ultimate-Easy-ESPHome_core_hw_speaker.yaml:20-21
Timestamp: 2024-12-24T22:40:00.309Z
Learning: The BLE addon uses a unique speaker component named mp_speaker and removes the media_player component entirely, so no rename from mp_speaker to mp_media_player is required there.
Learnt from: edwardtfn
PR: edwardtfn/TX-Ultimate-Easy#56
File: ESPHome/TX-Ultimate-Easy-ESPHome_core_hw_touch.yaml:18-147
Timestamp: 2024-12-23T03:35:56.090Z
Learning: The user clarified that the proposed YAML anchor refactoring approach will not work with ESPHome, and they intend to maintain the current implementation despite code duplication.
🪛 GitHub Check: Validate YAML
.github/workflows/validate_esphome.yml

[failure] 160-160:
160:1 [trailing-spaces] trailing spaces

🪛 GitHub Actions: Validate YAML (secondary files)
.github/workflows/validate_esphome.yml

[error] 160-160: trailing-spaces: trailing spaces detected

⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (8)
  • GitHub Check: 📦 basic (idf-beta)
  • GitHub Check: 📦 core (idf-beta)
  • GitHub Check: 📦 basic (idf-latest)
  • GitHub Check: 📦 core (idf-latest)
  • GitHub Check: 📦 basic (idf-beta)
  • GitHub Check: 📦 basic (idf-latest)
  • GitHub Check: 📦 core (idf-beta)
  • GitHub Check: 📦 core (idf-latest)

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

♻️ Duplicate comments (2)
.github/workflows/validate_esphome.yml (2)

53-53: .yml files still excluded from yamllint

The find command only covers *.yaml, silently skipping all workflow files (*.yml).
This was flagged previously but not fixed.

-run: find . -name "*.yaml" -exec yamllint -c ./.rules/yamllint.yml {} +
+run: |
+  find . \( -name "*.yaml" -o -name "*.yml" \) \
+       -exec yamllint -c ./.rules/yamllint.yml {} +

83-84: Incorrect input context – inputs.skip_dev is always empty

workflow_dispatch inputs must be referenced with github.event.inputs.<name>.
As written, the if expressions always evaluate as true, so dev builds are never skipped.

-if: success() && !inputs.skip_dev
+if: success() && (github.event.inputs.skip_dev != 'true')

Apply the same correction everywhere the input is referenced (see lines listed above).

Also applies to: 144-145, 210-211, 271-272, 299-300, 467-468

📜 Review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 4c0a838 and ba041a9.

📒 Files selected for processing (2)
  • .github/workflows/validate_esphome.yml (2 hunks)
  • ESPHome/TX-Ultimate-Easy-ESPHome_standard_hw_audio.yaml (1 hunks)
🧰 Additional context used
🧠 Learnings (3)
📓 Common learnings
Learnt from: edwardtfn
PR: edwardtfn/TX-Ultimate-Easy#112
File: .github/workflows/validate_esphome_dev.yml:52-210
Timestamp: 2025-07-29T08:10:32.072Z
Learning: Media player functionality is now supported by both Arduino and IDF frameworks in TX Ultimate Easy ESPHome configurations, removing the previous Arduino-only limitation.
Learnt from: edwardtfn
PR: edwardtfn/TX-Ultimate-Easy#73
File: ESPHome/TX-Ultimate-Easy-ESPHome_addon_media_player.yaml:14-20
Timestamp: 2024-12-26T21:18:44.593Z
Learning: In the TX Ultimate Easy ESPHome setup, the i2s_dout_pin for audio output is defined in respective speaker or media_player components rather than in the core_hw_audio package.
Learnt from: edwardtfn
PR: edwardtfn/TX-Ultimate-Easy#71
File: ESPHome/TX-Ultimate-Easy-ESPHome_core_hw_speaker.yaml:20-21
Timestamp: 2024-12-24T22:40:00.309Z
Learning: The BLE addon uses a unique speaker component named mp_speaker and removes the media_player component entirely, so no rename from mp_speaker to mp_media_player is required there.
Learnt from: edwardtfn
PR: edwardtfn/TX-Ultimate-Easy#56
File: ESPHome/TX-Ultimate-Easy-ESPHome_core_hw_touch.yaml:18-147
Timestamp: 2024-12-23T03:35:56.090Z
Learning: The user clarified that the proposed YAML anchor refactoring approach will not work with ESPHome, and they intend to maintain the current implementation despite code duplication.
ESPHome/TX-Ultimate-Easy-ESPHome_standard_hw_audio.yaml (3)

Learnt from: edwardtfn
PR: #73
File: ESPHome/TX-Ultimate-Easy-ESPHome_addon_media_player.yaml:14-20
Timestamp: 2024-12-26T21:18:44.593Z
Learning: In the TX Ultimate Easy ESPHome setup, the i2s_dout_pin for audio output is defined in respective speaker or media_player components rather than in the core_hw_audio package.

Learnt from: edwardtfn
PR: #112
File: .github/workflows/validate_esphome_dev.yml:52-210
Timestamp: 2025-07-29T08:10:32.072Z
Learning: Media player functionality is now supported by both Arduino and IDF frameworks in TX Ultimate Easy ESPHome configurations, removing the previous Arduino-only limitation.

Learnt from: edwardtfn
PR: #71
File: ESPHome/TX-Ultimate-Easy-ESPHome_core_hw_speaker.yaml:20-21
Timestamp: 2024-12-24T22:40:00.309Z
Learning: The BLE addon uses a unique speaker component named mp_speaker and removes the media_player component entirely, so no rename from mp_speaker to mp_media_player is required there.

.github/workflows/validate_esphome.yml (13)

Learnt from: CR
PR: edwardtfn/TX-Ultimate-Easy#0
File: .rules/yamllint.yml:0-0
Timestamp: 2025-07-29T12:55:24.801Z
Learning: Applies to *.{yaml,yml,.yamllint} : Comments in YAML files should be present and properly formatted (comments: level: warning)

Learnt from: CR
PR: edwardtfn/TX-Ultimate-Easy#0
File: .rules/yamllint.yml:0-0
Timestamp: 2025-07-29T12:55:24.801Z
Learning: Applies to *.{yaml,yml,.yamllint} : Hyphens must be used correctly in YAML files (hyphens: enable)

Learnt from: CR
PR: edwardtfn/TX-Ultimate-Easy#0
File: .rules/yamllint.yml:0-0
Timestamp: 2025-07-29T12:55:24.801Z
Learning: Applies to *.{yaml,yml,.yamllint} : Truthy values in YAML files should be checked (truthy: level: warning)

Learnt from: CR
PR: edwardtfn/TX-Ultimate-Easy#0
File: .rules/yamllint.yml:0-0
Timestamp: 2025-07-29T12:55:24.801Z
Learning: Applies to *.{yaml,yml,.yamllint} : Comments in YAML files should be properly indented (comments-indentation: level: warning)

Learnt from: CR
PR: edwardtfn/TX-Ultimate-Easy#0
File: .rules/yamllint.yml:0-0
Timestamp: 2025-07-29T12:55:24.801Z
Learning: Applies to *.{yaml,yml,.yamllint} : YAML files should have a document end marker (document-end: level: warning)

Learnt from: CR
PR: edwardtfn/TX-Ultimate-Easy#0
File: .rules/yamllint.yml:0-0
Timestamp: 2025-07-29T12:55:24.801Z
Learning: Applies to *.{yaml,yml,.yamllint} : YAML files should have a document start marker (document-start: level: warning)

Learnt from: CR
PR: edwardtfn/TX-Ultimate-Easy#0
File: .rules/yamllint.yml:0-0
Timestamp: 2025-07-29T12:55:24.801Z
Learning: Applies to *.{yaml,yml,.yamllint} : Indentation must be correct in YAML files (indentation: enable)

Learnt from: CR
PR: edwardtfn/TX-Ultimate-Easy#0
File: .rules/yamllint.yml:0-0
Timestamp: 2025-07-29T12:55:24.801Z
Learning: Applies to *.{yaml,yml,.yamllint} : Octal values in YAML files should be checked (octal-values: level: warning)

Learnt from: CR
PR: edwardtfn/TX-Ultimate-Easy#0
File: .rules/yamllint.yml:0-0
Timestamp: 2025-07-29T12:55:24.801Z
Learning: Applies to *.{yaml,yml,.yamllint} : Trailing spaces are not allowed in YAML files (trailing-spaces: enable)

Learnt from: CR
PR: edwardtfn/TX-Ultimate-Easy#0
File: .rules/yamllint.yml:0-0
Timestamp: 2025-07-29T12:55:24.801Z
Learning: Applies to *.{yaml,yml,.yamllint} : Braces must be used correctly in YAML files (braces: enable)

Learnt from: CR
PR: edwardtfn/TX-Ultimate-Easy#0
File: .rules/yamllint.yml:0-0
Timestamp: 2025-07-29T12:55:24.801Z
Learning: Applies to *.{yaml,yml,.yamllint} : YAML files must end with a new line (new-line-at-end-of-file: enable)

Learnt from: CR
PR: edwardtfn/TX-Ultimate-Easy#0
File: .rules/yamllint.yml:0-0
Timestamp: 2025-07-29T12:55:24.801Z
Learning: Applies to *.{yaml,yml,.yamllint} : Empty lines are enabled in YAML files (empty-lines: enable)

Learnt from: edwardtfn
PR: #56
File: ESPHome/TX-Ultimate-Easy-ESPHome_core_hw_touch.yaml:18-147
Timestamp: 2024-12-23T03:35:56.090Z
Learning: The user clarified that the proposed YAML anchor refactoring approach will not work with ESPHome, and they intend to maintain the current implementation despite code duplication.

⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (4)
  • GitHub Check: 🏗️ Arduino Core (latest)
  • GitHub Check: 🏗️ IDF Core (latest)
  • GitHub Check: 🏗️ Arduino Core (latest)
  • GitHub Check: 🏗️ IDF Core (latest)
🔇 Additional comments (1)
ESPHome/TX-Ultimate-Easy-ESPHome_standard_hw_audio.yaml (1)

23-24: Validate i2s_audio enum values

i2s_comm_fmt: stand_msb and channel: mono are not documented options in ESPHome 2025.x.
Accepted enums are typically (philips, msb, lsb, …) and channel expects left / right (or is omitted).

Please double-check against the current ESPHome schema or the generated C++ to avoid a compile-time failure.

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 0

♻️ Duplicate comments (1)
ESPHome/TX-Ultimate-Easy-ESPHome_standard_hw_speaker.yaml (1)

82-84: Fix compile-time guard to match the new build flag

The compile-time guard still checks for TX_ULTIMATE_EASY_STANDARD_HW_AUDIO but the build flag was changed to TX_ULTIMATE_EASY_STANDARD_HW_SPEAKER on line 41. This mismatch will cause incorrect error behavior.

Apply this fix to align the guard with the new build flag:

-          #if !defined(TX_ULTIMATE_EASY_STANDARD_HW_AUDIO)
-            #error "The package TX-Ultimate-Easy-ESPHome_standard_hw_audio.yaml is required."
+          #if !defined(TX_ULTIMATE_EASY_STANDARD_HW_SPEAKER)
+            #error "The package TX-Ultimate-Easy-ESPHome_standard_hw_speaker.yaml is required."
🧹 Nitpick comments (3)
ESPHome/TX-Ultimate-Easy-ESPHome_standard_hw_speaker.yaml (1)

182-185: Fix YAML comment formatting

The commented configuration options have formatting issues that violate YAML linting rules - missing starting spaces in comments.

Apply this fix to properly format the comments:

-    #timeout: never
-    #bits_per_sample: 16bit
-    #sample_rate: 48000
-    #buffer_duration: 500ms
+    # timeout: never
+    # bits_per_sample: 16bit
+    # sample_rate: 48000
+    # buffer_duration: 500ms
ESPHome/TX-Ultimate-Easy-ESPHome_standard_media_player.yaml (2)

32-39: Fix YAML comment formatting in pipeline configuration

The commented configuration options have missing starting spaces, violating YAML linting rules.

Apply this fix to properly format the comments:

-      #format: WAV
-      #num_channels: 1
-      #sample_rate: 48000
+      # format: WAV
+      # num_channels: 1
+      # sample_rate: 48000
     media_pipeline:
       speaker: media_spk_resampling_input
-      #format: FLAC
-      #num_channels: 1
-      #sample_rate: 48000
+      # format: FLAC
+      # num_channels: 1
+      # sample_rate: 48000

40-44: Fix comment indentation and formatting

The ducking configuration comment block has both indentation and formatting issues.

Apply this fix to properly format the comments:

-    #on_announcement:
-    #  - mixer_speaker.apply_ducking:
-    #      id: media_speaker_embedded
-    #      decibel_reduction: 20
-    #      duration: 0.0s
+    # on_announcement:
+    #   - mixer_speaker.apply_ducking:
+    #       id: media_speaker_embedded
+    #       decibel_reduction: 20
+    #       duration: 0.0s
📜 Review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between ba041a9 and 912607d.

📒 Files selected for processing (3)
  • ESPHome/TX-Ultimate-Easy-ESPHome_standard_hw_audio.yaml (1 hunks)
  • ESPHome/TX-Ultimate-Easy-ESPHome_standard_hw_speaker.yaml (2 hunks)
  • ESPHome/TX-Ultimate-Easy-ESPHome_standard_media_player.yaml (3 hunks)
✅ Files skipped from review due to trivial changes (1)
  • ESPHome/TX-Ultimate-Easy-ESPHome_standard_hw_audio.yaml
🧰 Additional context used
🧠 Learnings (3)
📓 Common learnings
Learnt from: edwardtfn
PR: edwardtfn/TX-Ultimate-Easy#112
File: .github/workflows/validate_esphome_dev.yml:52-210
Timestamp: 2025-07-29T08:10:32.072Z
Learning: Media player functionality is now supported by both Arduino and IDF frameworks in TX Ultimate Easy ESPHome configurations, removing the previous Arduino-only limitation.
Learnt from: edwardtfn
PR: edwardtfn/TX-Ultimate-Easy#73
File: ESPHome/TX-Ultimate-Easy-ESPHome_addon_media_player.yaml:14-20
Timestamp: 2024-12-26T21:18:44.593Z
Learning: In the TX Ultimate Easy ESPHome setup, the i2s_dout_pin for audio output is defined in respective speaker or media_player components rather than in the core_hw_audio package.
Learnt from: edwardtfn
PR: edwardtfn/TX-Ultimate-Easy#71
File: ESPHome/TX-Ultimate-Easy-ESPHome_core_hw_speaker.yaml:20-21
Timestamp: 2024-12-24T22:40:00.309Z
Learning: The BLE addon uses a unique speaker component named mp_speaker and removes the media_player component entirely, so no rename from mp_speaker to mp_media_player is required there.
Learnt from: edwardtfn
PR: edwardtfn/TX-Ultimate-Easy#56
File: ESPHome/TX-Ultimate-Easy-ESPHome_core_hw_touch.yaml:18-147
Timestamp: 2024-12-23T03:35:56.090Z
Learning: The user clarified that the proposed YAML anchor refactoring approach will not work with ESPHome, and they intend to maintain the current implementation despite code duplication.
ESPHome/TX-Ultimate-Easy-ESPHome_standard_hw_speaker.yaml (3)

Learnt from: edwardtfn
PR: #73
File: ESPHome/TX-Ultimate-Easy-ESPHome_addon_media_player.yaml:14-20
Timestamp: 2024-12-26T21:18:44.593Z
Learning: In the TX Ultimate Easy ESPHome setup, the i2s_dout_pin for audio output is defined in respective speaker or media_player components rather than in the core_hw_audio package.

Learnt from: edwardtfn
PR: #71
File: ESPHome/TX-Ultimate-Easy-ESPHome_core_hw_speaker.yaml:20-21
Timestamp: 2024-12-24T22:40:00.309Z
Learning: The BLE addon uses a unique speaker component named mp_speaker and removes the media_player component entirely, so no rename from mp_speaker to mp_media_player is required there.

Learnt from: edwardtfn
PR: #112
File: .github/workflows/validate_esphome_dev.yml:52-210
Timestamp: 2025-07-29T08:10:32.072Z
Learning: Media player functionality is now supported by both Arduino and IDF frameworks in TX Ultimate Easy ESPHome configurations, removing the previous Arduino-only limitation.

ESPHome/TX-Ultimate-Easy-ESPHome_standard_media_player.yaml (3)

Learnt from: edwardtfn
PR: #73
File: ESPHome/TX-Ultimate-Easy-ESPHome_addon_media_player.yaml:14-20
Timestamp: 2024-12-26T21:18:44.593Z
Learning: In the TX Ultimate Easy ESPHome setup, the i2s_dout_pin for audio output is defined in respective speaker or media_player components rather than in the core_hw_audio package.

Learnt from: edwardtfn
PR: #71
File: ESPHome/TX-Ultimate-Easy-ESPHome_core_hw_speaker.yaml:20-21
Timestamp: 2024-12-24T22:40:00.309Z
Learning: The BLE addon uses a unique speaker component named mp_speaker and removes the media_player component entirely, so no rename from mp_speaker to mp_media_player is required there.

Learnt from: edwardtfn
PR: #112
File: .github/workflows/validate_esphome_dev.yml:52-210
Timestamp: 2025-07-29T08:10:32.072Z
Learning: Media player functionality is now supported by both Arduino and IDF frameworks in TX Ultimate Easy ESPHome configurations, removing the previous Arduino-only limitation.

🪛 GitHub Check: Code scan (YAML)
ESPHome/TX-Ultimate-Easy-ESPHome_standard_hw_speaker.yaml

[warning] 183-183:
183:6 [comments] missing starting space in comment


[warning] 182-182:
182:6 [comments] missing starting space in comment

ESPHome/TX-Ultimate-Easy-ESPHome_standard_media_player.yaml

[warning] 40-40:
40:5 [comments-indentation] comment not indented like content


[warning] 40-40:
40:6 [comments] missing starting space in comment


[warning] 39-39:
39:8 [comments] missing starting space in comment


[warning] 38-38:
38:8 [comments] missing starting space in comment


[warning] 37-37:
37:8 [comments] missing starting space in comment


[warning] 34-34:
34:8 [comments] missing starting space in comment


[warning] 33-33:
33:8 [comments] missing starting space in comment


[warning] 32-32:
32:8 [comments] missing starting space in comment

⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (4)
  • GitHub Check: 🏗️ IDF Core (latest)
  • GitHub Check: 🏗️ Arduino Core (latest)
  • GitHub Check: 🏗️ Arduino Core (latest)
  • GitHub Check: 🏗️ IDF Core (latest)
🔇 Additional comments (6)
ESPHome/TX-Ultimate-Easy-ESPHome_standard_hw_speaker.yaml (2)

41-41: Build flag updated appropriately for speaker hardware abstraction

The build flag change from TX_ULTIMATE_EASY_STANDARD_SPEAKER to TX_ULTIMATE_EASY_STANDARD_HW_SPEAKER properly aligns with the hardware-specific naming convention used throughout the codebase.


187-196: LGTM: Speaker amplifier switch properly configured

The new GPIO switch for the speaker amplifier is well-configured with appropriate settings:

  • GPIO26 with inverted logic matches hardware requirements
  • ALWAYS_OFF restore mode prevents unwanted power-on behavior
  • Internal entity with config category properly isolates this as a system component
ESPHome/TX-Ultimate-Easy-ESPHome_standard_media_player.yaml (4)

15-15: Package dependency updated correctly

The change from standard_hw_audio to standard_hw_speaker aligns with the hardware abstraction refactoring and matches the updated build flag in the speaker package.


26-44: Media player architecture modernized with speaker platform

The refactoring from i2s_audio platform to speaker platform introduces a more flexible pipeline-based architecture:

  • Separate announcement and media pipelines allow for better audio mixing
  • Codec support and buffering configurations are appropriate for media playback
  • The commented ducking configuration shows consideration for announcement handling

This change aligns with the retrieved learning that media player functionality is now supported by both Arduino and IDF frameworks.


55-57: Compile-time guard updated correctly

The guard now checks for TX_ULTIMATE_EASY_STANDARD_HW_SPEAKER which matches the new package dependency and build flag naming convention.


62-74: Well-designed speaker pipeline architecture

The speaker configuration implements a sophisticated audio pipeline:

  • Mixer speaker combines announcement and media sources
  • Resampler speakers handle different audio formats and sample rates
  • Clear separation of concerns between announcement and media audio paths

This architecture provides the flexibility needed for modern media player functionality while maintaining compatibility with the existing speaker hardware.

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 0

🧹 Nitpick comments (3)
ESPHome/TX-Ultimate-Easy-ESPHome_standard_media_player.yaml (2)

50-59: Use std::abs to avoid ambiguous overload on some toolchains

abs() is pulled in via <cstdlib> for int, long, etc.
When both uint8_t and int are involved the implicit promotion can confuse certain ESP-IDF/xtensa builds.
Prefer std::abs with an explicit int cast to guarantee the signed overload is chosen.

-            if (abs(static_cast<int>(current_volume_percentage) - static_cast<int>(id(last_media_player_volume))) > 1) {  // 1% threshold
+            if (std::abs(static_cast<int>(current_volume_percentage) -
+                         static_cast<int>(id(last_media_player_volume))) > 1) {  // 1% threshold

78-83: Quote single-line lambda for better YAML parsing robustness

Unquoted inline tag values occasionally trip YAML linters.
Quoting the scalar keeps tooling happy without changing behaviour.

-            volume: !lambda return x / 100.0f;
+            volume: !lambda 'return x / 100.0f;'
README.md (1)

55-57: Replace wordy phrase “in succession”

Static-analysis flagged the wording. “Consecutively” conveys the same meaning more concisely.

-2. **Alternative**: If serial flashing isn't possible, flash OTA twice consecutively to improve success rate
+2. **Alternative**: If serial flashing isn't possible, flash OTA twice consecutively to improve success rate
📜 Review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between a4340da and 796eb76.

📒 Files selected for processing (6)
  • ESPHome/TX-Ultimate-Easy-ESPHome_addon_media_player.yaml (0 hunks)
  • ESPHome/TX-Ultimate-Easy-ESPHome_core_hw_media_player.yaml (0 hunks)
  • ESPHome/TX-Ultimate-Easy-ESPHome_standard_hw_audio.yaml (2 hunks)
  • ESPHome/TX-Ultimate-Easy-ESPHome_standard_hw_speaker.yaml (2 hunks)
  • ESPHome/TX-Ultimate-Easy-ESPHome_standard_media_player.yaml (1 hunks)
  • README.md (6 hunks)
💤 Files with no reviewable changes (2)
  • ESPHome/TX-Ultimate-Easy-ESPHome_core_hw_media_player.yaml
  • ESPHome/TX-Ultimate-Easy-ESPHome_addon_media_player.yaml
🚧 Files skipped from review as they are similar to previous changes (2)
  • ESPHome/TX-Ultimate-Easy-ESPHome_standard_hw_audio.yaml
  • ESPHome/TX-Ultimate-Easy-ESPHome_standard_hw_speaker.yaml
🧰 Additional context used
📓 Path-based instructions (1)
**/*.md

📄 CodeRabbit Inference Engine (.rules/markdownlint.yml)

Enforce a maximum line length of 200 characters in Markdown files (MD013)

Files:

  • README.md
🧠 Learnings (3)
📓 Common learnings
Learnt from: edwardtfn
PR: edwardtfn/TX-Ultimate-Easy#112
File: .github/workflows/validate_esphome_dev.yml:52-210
Timestamp: 2025-07-29T08:10:32.072Z
Learning: Media player functionality is now supported by both Arduino and IDF frameworks in TX Ultimate Easy ESPHome configurations, removing the previous Arduino-only limitation.
Learnt from: edwardtfn
PR: edwardtfn/TX-Ultimate-Easy#73
File: ESPHome/TX-Ultimate-Easy-ESPHome_addon_media_player.yaml:14-20
Timestamp: 2024-12-26T21:18:44.593Z
Learning: In the TX Ultimate Easy ESPHome setup, the i2s_dout_pin for audio output is defined in respective speaker or media_player components rather than in the core_hw_audio package.
Learnt from: edwardtfn
PR: edwardtfn/TX-Ultimate-Easy#71
File: ESPHome/TX-Ultimate-Easy-ESPHome_core_hw_speaker.yaml:20-21
Timestamp: 2024-12-24T22:40:00.309Z
Learning: The BLE addon uses a unique speaker component named mp_speaker and removes the media_player component entirely, so no rename from mp_speaker to mp_media_player is required there.
Learnt from: edwardtfn
PR: edwardtfn/TX-Ultimate-Easy#56
File: ESPHome/TX-Ultimate-Easy-ESPHome_core_hw_touch.yaml:18-147
Timestamp: 2024-12-23T03:35:56.090Z
Learning: The user clarified that the proposed YAML anchor refactoring approach will not work with ESPHome, and they intend to maintain the current implementation despite code duplication.
ESPHome/TX-Ultimate-Easy-ESPHome_standard_media_player.yaml (3)

Learnt from: edwardtfn
PR: #73
File: ESPHome/TX-Ultimate-Easy-ESPHome_addon_media_player.yaml:14-20
Timestamp: 2024-12-26T21:18:44.593Z
Learning: In the TX Ultimate Easy ESPHome setup, the i2s_dout_pin for audio output is defined in respective speaker or media_player components rather than in the core_hw_audio package.

Learnt from: edwardtfn
PR: #71
File: ESPHome/TX-Ultimate-Easy-ESPHome_core_hw_speaker.yaml:20-21
Timestamp: 2024-12-24T22:40:00.309Z
Learning: The BLE addon uses a unique speaker component named mp_speaker and removes the media_player component entirely, so no rename from mp_speaker to mp_media_player is required there.

Learnt from: edwardtfn
PR: #112
File: .github/workflows/validate_esphome_dev.yml:52-210
Timestamp: 2025-07-29T08:10:32.072Z
Learning: Media player functionality is now supported by both Arduino and IDF frameworks in TX Ultimate Easy ESPHome configurations, removing the previous Arduino-only limitation.

README.md (4)

Learnt from: edwardtfn
PR: #112
File: .github/workflows/validate_esphome_dev.yml:52-210
Timestamp: 2025-07-29T08:10:32.072Z
Learning: Media player functionality is now supported by both Arduino and IDF frameworks in TX Ultimate Easy ESPHome configurations, removing the previous Arduino-only limitation.

Learnt from: edwardtfn
PR: #73
File: ESPHome/TX-Ultimate-Easy-ESPHome_addon_media_player.yaml:14-20
Timestamp: 2024-12-26T21:18:44.593Z
Learning: In the TX Ultimate Easy ESPHome setup, the i2s_dout_pin for audio output is defined in respective speaker or media_player components rather than in the core_hw_audio package.

Learnt from: edwardtfn
PR: #115
File: ESPHome/TX-Ultimate-Easy-ESPHome_core_hw_leds.yaml:162-170
Timestamp: 2025-07-30T17:43:59.397Z
Learning: In ESPHome YAML files, anchors can safely contain id and name fields because when inherited using <<: *anchor_name, the inheriting object's own id and name fields will override the anchor's values. This is standard YAML merge key behavior where the inheriting object's keys take precedence.

Learnt from: edwardtfn
PR: #71
File: ESPHome/TX-Ultimate-Easy-ESPHome_core_hw_speaker.yaml:20-21
Timestamp: 2024-12-24T22:40:00.309Z
Learning: The BLE addon uses a unique speaker component named mp_speaker and removes the media_player component entirely, so no rename from mp_speaker to mp_media_player is required there.

🪛 LanguageTool
README.md

[style] ~67-~67: ‘in succession’ might be wordy. Consider a shorter alternative.
Context: ...e may not update correctly. Flash twice in succession to ensure both firmware partitions cont...

(EN_WORDINESS_PREMIUM_IN_SUCCESSION)

⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (4)
  • GitHub Check: 🏗️ Arduino Core (latest)
  • GitHub Check: 🏗️ IDF Core (latest)
  • GitHub Check: 🏗️ IDF Core (latest)
  • GitHub Check: 🏗️ Arduino Core (latest)
🔇 Additional comments (1)
ESPHome/TX-Ultimate-Easy-ESPHome_standard_media_player.yaml (1)

132-144: Verify that all referenced speakers are defined

mixer_speaker_embedded relies on:

  • speaker_embedded
  • announcement_speaker_embedded
  • media_speaker_embedded

None of these IDs are declared in this file. If they are supplied only by standard_hw_speaker.yaml, compilation will fail whenever this package is used standalone (e.g., in tests).

Please confirm that each ID is guaranteed to exist after package expansion or add stub speaker: definitions here.

@edwardtfn edwardtfn linked an issue Jul 31, 2025 that may be closed by this pull request
@edwardtfn edwardtfn removed a link to an issue Jul 31, 2025
@edwardtfn edwardtfn merged commit 11807ce into main Aug 1, 2025
50 checks passed
@edwardtfn edwardtfn deleted the idf-as-default branch August 8, 2025 14:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Speaker issue? Am i doing something wrong? Loud static noise and then it freezes BLE support

1 participant