Skip to content

Add Firmware Channel switching and serve the end-user image for OTA#45

Closed
bharvey88 wants to merge 1 commit into
betafrom
firmware-channel
Closed

Add Firmware Channel switching and serve the end-user image for OTA#45
bharvey88 wants to merge 1 commit into
betafrom
firmware-channel

Conversation

@bharvey88

Copy link
Copy Markdown
Contributor

Version: 26.7.7.1

What does this implement/fix?

Same Stable/Beta firmware switching as CAST-1 (naming per ApolloAutomation/CAST-1#43):

  • Firmware Channel select (Stable/Beta) sets the OTA manifest URL via a new apply_ota_source script. Stable = GitHub Pages (main branch builds), Beta = rolling beta pre-release assets.
  • Firmware Update button force-installs the selected channel's firmware. It re-applies the manifest URL first (so a just-switched channel is fetched before forcing) and temporarily disables BLE during the download to free heap for TLS (no-op on non-BLE images).
  • Updates now serve the end-user image: PUMP-1_Minimal.yaml (the adopted end-user config) gains the managed update system, and CI serves it at firmware/; PUMP-1.yaml (improv + BLE) moves to firmware-factory/ for the web installer only. Fielded devices leave the improv image on their next update.
  • build-beta.yml (new): pushes to beta build the end-user image(s) and publish them to a rolling beta pre-release with manifests rewritten to absolute URLs.
  • update component id renamed firmware_update -> update_http_request to match the other Apollo repos.

Both images config-validated on ESPHome 2026.6.4. Not yet tested on hardware.

Types of changes

  • Bugfix (fixed change that fixes an issue)
  • New feature (thanks!)
  • Breaking change (repair/feature that breaks existing functionality)
  • Dependency Update - Does not publish
  • Other - Does not publish
  • Website of github readme file update - Does not publish
  • Github workflows - Does not publish

Checklist / Checklijst:

  • The code change has been tested and works locally
  • The code change has not yet been tested

If user-visible functionality or configuration variables are added/modified:

  • Added/updated documentation for the web page

🤖 Generated with Claude Code

@coderabbitai

coderabbitai Bot commented Jul 7, 2026

Copy link
Copy Markdown

Warning

Review limit reached

@bharvey88, you've reached your PR review limit, so we couldn't start this review.

Next review available in: 59 minutes

Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available.
You're only billed for reviews past your plan's rate limits ($0.25/file).

How can I continue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews.

How do review limits work?

CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability.

For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window.

Please refer docs for additional details.

Review details
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: e951d039-9ab7-4fa8-ae07-2ef30329b914

📥 Commits

Reviewing files that changed from the base of the PR and between 1cf2bfa and 2de861a.

📒 Files selected for processing (7)
  • .github/workflows/build-beta.yml
  • .github/workflows/build.yml
  • Integrations/ESPHome/Core.yaml
  • Integrations/ESPHome/PUMP-1.yaml
  • Integrations/ESPHome/PUMP-1_Minimal.yaml
  • Integrations/ESPHome/beta-channel/PUMP-1_Minimal.yaml
  • static/index.html
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch firmware-channel

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.

Same feature as CAST-1 and AIR-1 (ApolloAutomation/AIR-1#107):

- Firmware Channel select (Stable/Beta) sets the OTA manifest URL via
  a new apply_ota_source script; Firmware Update button force-installs.
- PUMP-1_Minimal.yaml (the adopted end-user config) gains the managed
  update system so fielded devices can keep updating after leaving the
  improv image.
- build.yml now serves PUMP-1_Minimal.yaml at firmware/; PUMP-1.yaml
  (improv + BLE) moves to firmware-factory/ for the web installer only.
- build-beta.yml publishes beta builds to a rolling beta pre-release.
- update component id renamed firmware_update -> update_http_request to
  match the other Apollo repos.

Beta-channel builds compile thin beta-channel/ wrapper yamls so the
Firmware Channel select defaults to Beta on firmware obtained from the
beta channel (fresh flashes only; stored choices still win).

Version: 26.7.8.1

🤖 Generated with [Claude Code](https://claude.com/claude-code)
@bharvey88

Copy link
Copy Markdown
Contributor Author

Superseded by the unified rebuild (see the new PR referencing this one): same channel select and image flip, plus the http_request buffer fixes this predates, boot-time channel re-apply, the pre-OTA BLE disable removed per MSR-1 #103, the Minimal on_boot mapping-vs-list merge fix, and min_version raised to the update-system floor.

@bharvey88 bharvey88 closed this Jul 12, 2026
bharvey88 added a commit that referenced this pull request Jul 12, 2026
…l OTA

Rebuild of the earlier firmware-channel port on the pattern MSR-1 shipped
as 26.7.9.1 (ApolloAutomation/MSR-1 #100/#103/#104):

- NEW: bluetooth_proxy + esp32_ble_tracker compile into every image; a
  "Bluetooth Proxy" switch (default off, persisted, re-applied at boot)
  starts/stops scanning at runtime. Always-on C6/8MB device - a clean
  proxy candidate; nothing changes until a user turns the switch on.
- Firmware Channel select (Stable/Beta) + apply_ota_source doing a direct
  set_source_url swap from ota_stable_manifest/ota_beta_manifest subs; the
  channel is re-applied at boot (on_boot -100)
- Firmware Update button simplified: no pre-OTA BLE disable (ESPHome's OTA
  quiesces BLE itself)
- http_request consolidated into Core.yaml with the proven buffer sizes
  (rx 5120 / tx 2048 for GitHub release redirects)
- PUMP-1_Minimal on_boot converted to list form so Core's boot logic
  (pump safety init, refill-mode application) still runs on the image
  that now serves OTA
- PUMP-1_Minimal gains the managed-update machinery and takes over Pages
  firmware/ for OTA/adoption; the improv image moves to firmware-factory/
  (installer page repointed)
- beta-channel/ wrapper defaults the select to Beta; build-beta.yml
  publishes the manifest (absolute URLs) to the rolling beta-fw pre-release
- min_version 2025.11.0 (update-system floor); version 26.7.12.1

Supersedes #45.

🤖 Generated with [Claude Code](https://claude.com/claude-code)
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.

1 participant