Unify BLE into one firmware: runtime Bluetooth Proxy switch + channel-only OTA#100
Conversation
…-only OTA Replaces the build-time BLE variant machinery with runtime toggles: - Compile bluetooth_proxy + esp32_ble_tracker into Core.yaml so every variant inherits it (base ~94.1% flash, Factory ~95.4% - both fit 4MB). - Add a "Bluetooth Proxy" switch (default off) that starts/stops scanning via esp32_ble_tracker; the esp32_ble stack stays up so esp32_improv keeps working on the Factory image. - Remove the firmware_ble manifest selector. apply_ota_source is now channel-only, using per-variant manifest bases (ota_stable_manifest / ota_beta_manifest) so legacy MSR-1_BLE devices keep their firmware-ble manifest. - Delete the manifest-matching guard and simplify the Firmware Update flow: drop the BLE stack for the TLS download, restore it + the switch's scan state on the not-started path, and let the post-update reboot restore the switch. This also fixes the unconditional BLE re-enable CodeRabbit flagged. - MSR-1_BLE.yaml: drop its now-inherited bluetooth_proxy; add the manifest subs. Part of the single 26.7.9.1 release; no version bump. 🤖 Generated with [Claude Code](https://claude.com/claude-code)
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (2)
WalkthroughThe ESPHome Core configuration replaces variant-based BLE/OTA selection with per-channel manifest substitutions (ota_stable_manifest, ota_beta_manifest) and a new template switch (bluetooth_proxy_switch) controlling BLE scanning. The Firmware Update flow and apply_ota_source script are simplified accordingly, removing manifest/channel mismatch validation. MSR-1_BLE.yaml adds legacy manifest substitutions and drops bluetooth_proxy active setting. ChangesOTA manifest and Bluetooth proxy switch refactor
Estimated code review effort: 3 (Moderate) | ~25 minutes Possibly related PRs
Poem
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
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 |
Version: 26.7.9.1 (no change — part of the single release)
What does this implement/fix?
Collapses the build-time
_BLEvariant into one firmware where Bluetooth and the update channel are runtime controls, and rips out the fragile manifest-matching machinery (the CodeRabbit-flagged OTA re-enable bug goes with it).bluetooth_proxy+esp32_ble_trackercompiled intoCore.yaml— every variant inherits it. Measured flash: base 94.1%, Factory 95.4% (both fit the 4MB app partition).on→esp32_ble_tracker.start_scan,off→stop_scan. Theesp32_blestack stays up soesp32_improvprovisioning still works on Factory.firmware_blemanifest selector.apply_ota_sourceis now channel-only (Stable/Beta) with per-variant manifest bases — legacyMSR-1_BLE.yamlkeeps itsfirmware-blemanifest via substitution overrides.MSR-1_BLE.yaml: dropped its now-inheritedbluetooth_proxy; added the manifest substitutions.Follow-ups (not in this PR): retire
beta-channel/configs, reconcile the publish pipeline, remove the now-vestigialble_firmwaresubstitution.Note for the reviewer: the exact
esp32_ble_tracker.start_scan/stop_scanaction form (with/without a trackerid:) is confirmed at compile — CI is the check.Types of changes
Checklist / Checklijst:
If user-visible functionality or configuration variables are added/modified:
🤖 Generated with Claude Code
Summary by CodeRabbit
New Features
Bug Fixes