Skip to content

Add Internet OTA support for companion radio (usb/ble/wifi)#6

Merged
polipl merged 1 commit into
mainfrom
feature/companion-internet-ota
Jun 7, 2026
Merged

Add Internet OTA support for companion radio (usb/ble/wifi)#6
polipl merged 1 commit into
mainfrom
feature/companion-internet-ota

Conversation

@polipl
Copy link
Copy Markdown
Owner

@polipl polipl commented Jun 7, 2026

Summary

  • Extends InternetOTA with an optional OTA_VARIANT path segment so the manifest URL can address companion's per-variant server layout (data/firmware/companion/<board>/<usb|ble|wifi>/manifest.json), while the repeater's two-level layout (data/firmware/repeater/<board>/) stays unchanged.
  • For usb/ble companion builds (no permanent WiFi link), the periodic check reuses board.startInternetOTA exactly like simple_repeater — opens its own on-demand WiFiConnect (via WIFI_SSID_1../WIFI_PWD_1..) and disconnects after.
  • For wifi companion builds, which stay permanently connected for the app TCP bridge, the check reuses that existing WiFi link directly instead of opening a second WiFiConnect (which would disconnect the bridge, since WiFiMulti::run() drops any current connection not in its own AP list).

Test plan

  • pio run succeeds for all 9 companion environments (usb/ble/wifi × heltec_v4/heltec_v3/xiao_s3_wio)
  • Verified constructed manifest URLs match the new server layout for all variants (companion//<usb|ble|wifi>/manifest.json and repeater//manifest.json)

🤖 Generated with Claude Code

Extends InternetOTA with an optional OTA_VARIANT path segment so the
manifest URL can address companion's per-variant server layout
(data/firmware/companion/<board>/<usb|ble|wifi>/), while the repeater's
two-level layout (data/firmware/repeater/<board>/) stays unchanged.

For usb/ble builds (no permanent WiFi link), the periodic check reuses
board.startInternetOTA exactly like simple_repeater — it opens its own
on-demand WiFiConnect via WIFI_SSID_1../WIFI_PWD_1.. and disconnects
after. For wifi builds, which stay permanently connected for the app
TCP bridge, the check instead reuses that existing WiFi link directly
(spinning up a second WiFiConnect would disconnect the bridge, since
WiFiMulti::run() drops any current connection not in its own AP list).

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@polipl polipl merged commit c035d2f into main Jun 7, 2026
12 checks passed
@polipl polipl deleted the feature/companion-internet-ota branch June 7, 2026 18:10
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