Skip to content

feat(companion): add usb_tcp envs for V4 R8, V4 R8 TFT, V4 TFT and WSL3 - #7

Merged
Elektr0Vodka merged 2 commits into
mainfrom
Feat/heltec-usb-tcp-envs
Oct 16, 2026
Merged

Elektr0Vodka merged 2 commits into
mainfrom
Feat/heltec-usb-tcp-envs

Conversation

@Elektr0Vodka

Copy link
Copy Markdown
Owner

What changed

New meshcomod multi-transport (USB + TCP + WebSocket + BLE) companion envs, each with the SNMP agent and HTTP OTA, built the same way as Heltec_v3_companion_radio_usb_tcp:

Env Board Display / UI
heltec_v4_r8_companion_radio_usb_tcp Heltec V4 R8 (16 MB flash, 8 MB PSRAM) SSD1306, ui-new
heltec_v4_r8_tft_companion_radio_usb_tcp Heltec V4 R8 TFT ST7789, ui-new
heltec_v4_tft_companion_radio_usb_tcp Heltec V4 TFT, without the LVGL touch UI ST7789, ui-new
Heltec_WSL3_companion_radio_usb_tcp Wireless Stick Lite V3 headless, like the Xiao

It also carries feat(companion): enable SNMP on Wireless Paper and Xiao S3 WIO. That commit was pushed to Feat/companion-snmp a few minutes after #4 merged, so it never reached main: today Paper and Xiao build without SNMP even though #4's description listed them.

docs/companion_snmp.md lists the new envs and their sizes.

Why

These boards only had upstream's single-transport _usb, _ble and _wifi companions, so they had no TCP/WebSocket clients, no SNMP and no in-firmware OTA. The receive filter was already in every companion build; this brings the rest of the meshcomod companion feature set to them.

OTA

  • The names end in _companion_radio_usb_tcp, so build.sh (from feat(companion): add ota check and ota update from the OTA manifest #6) bakes OTA_VARIANT = env name and OTA_MANIFEST_BASE, and writes out/<env>.partsig. Checked: all four images contain the manifest base URL and their env name, and all four partsigs are written.
  • All four use the board's default partition table (V4 family default_16MB, WSL3 default_8MB). The non-touch heltec_v4_tft_companion_radio_usb_tcp therefore has a different partsig from heltec_v4_tft_companion_radio_usb_tcp_touch, so ota update refuses to cross between them (USB flash needed), which is correct.
  • ota url and ota start work as on the other usb_tcp envs (esp32_ota libs and helpers/esp32 are included).

Not in this PR: release, flasher and OTA server follow-ups

Until these are done the envs build locally and in pr-build-check only if added there, but are not released.

  1. Release list: add the four envs to MESHCOMOD_COMPANION_ENVS in build.sh. That alone makes build-companion-firmwares publish them to the GitHub Release.
  2. Board lists in docs: build.sh help text (line 24), the comment in .github/workflows/build-companion-firmwares.yml, the companion row in docs/CI_RELEASES.md, and the board table and env list in README.md.
  3. CI build check (optional): add them to the matrix in .github/workflows/pr-build-check.yml.
  4. Web flasher (flasher.meshcomod.com / meshcomod-client): add device entries for the four boards, reading <env>.bin / <env>-merged.bin from the release assets. That repo is not here, so this is a change there.
  5. DMC Toolbox (Dutch-Meshcore-Toolbox/public/community-firmware.json): its meshcomod devices point at ALLFATHER-BV/meshcomod prebuilt/ files, not this fork's releases. New boards only belong there if they are published where it reads from.
  6. OTA server (DutchMeshCore-OTA): nothing to change. It selects companion assets by the _companion_radio_usb_tcp suffix, so new envs are served once they are in the release. The env list in meshcomod-companion-ota-handoff.md is documentation only. Note that heltec_v4_tft_companion_radio_usb_tcp is a prefix of heltec_v4_tft_companion_radio_usb_tcp_touch: the server must match env names exactly, never by prefix.
  7. Legacy prebuilt/ scripts (scripts/copy-release-bins.sh, scripts/validate-prebuilt-release-folder.sh): only if that flow is still used. CI releases replaced it.

How it was tested

sh build.sh build-firmware <env> with FIRMWARE_VERSION=v1.18.0.1, DISABLE_DEBUG=1, after rebasing on #6:

Env Flash Static RAM App slot used
heltec_v4_r8_companion_radio_usb_tcp 1,635,957 B 110,448 B 25.0% of 6.25 MB
heltec_v4_r8_tft_companion_radio_usb_tcp 1,639,833 B 110,584 B 25.0% of 6.25 MB
heltec_v4_tft_companion_radio_usb_tcp 1,634,033 B 110,612 B 24.9% of 6.25 MB
Heltec_WSL3_companion_radio_usb_tcp 1,609,669 B 110,248 B 48.2% of 3.19 MB

Paper and Xiao with SNMP were built before #6 landed: +33,156 B / +33,020 B flash and +344 B static RAM each against the same tree without the flag.

Not tested on hardware. Nobody here has flashed these boards with the new envs. Pin use comes from the existing _wifi envs of the same boards.

Firmware and build impact

Four new envs, and SNMP on two existing ones (Paper, Xiao). No source changes, no prefs, protocol or OTA naming change. No version bump.

Feat/companion-snmp-tier1 also edits docs/companion_snmp.md; the two branches merge cleanly in either order.

No issue to close.

Same WITH_SNMP flag and library as the V3 and V4 OLED companions, so
every non-touch Wi-Fi companion in the release set has the agent.

Size vs the same tree without the flag: Paper +33,156 B flash, +344 B
static RAM; Xiao +33,020 B flash, +344 B static RAM. Both start from
about 40 KB more static RAM than the V3, so the docs flag them as the
boards to check for free heap on hardware.
These boards only had upstream's single-transport _usb, _ble and _wifi
companions. Add meshcomod multi-transport (USB + TCP + WebSocket + BLE)
envs with the SNMP agent and HTTP OTA, built the same way as the V3:

- heltec_v4_r8_companion_radio_usb_tcp (SSD1306, ui-new)
- heltec_v4_r8_tft_companion_radio_usb_tcp (ST7789, ui-new)
- heltec_v4_tft_companion_radio_usb_tcp (ST7789, ui-new; the V4 TFT
  without the LVGL touch UI)
- Heltec_WSL3_companion_radio_usb_tcp (headless, like the Xiao)

The names end in _companion_radio_usb_tcp, so build.sh bakes the
manifest OTA variant and base and writes out/<env>.partsig for them,
and the OTA server's suffix rule picks them up without a server change.
All four use the board's default partition table (V4 family 16 MB, WSL3
8 MB), so the touch build's custom layout is never confused with the
non-touch V4 TFT: partSig refuses an OTA across the two.

Not added to the release list (MESHCOMOD_COMPANION_ENVS), CI or the
flasher yet. Built with build.sh, not tested on hardware.
@Elektr0Vodka
Elektr0Vodka merged commit 9eb3bcf into main Oct 16, 2026
4 checks passed
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