Skip to content

HA bridge: per-alarm-type sensors + install fix; test cycle is 6 steps not 8 - #133

Merged
andy778 merged 2 commits into
mainfrom
fix/issue-113-bridge-and-testcycle-docs
Nov 28, 2026
Merged

andy778 merged 2 commits into
mainfrom
fix/issue-113-bridge-and-testcycle-docs

Conversation

@andy778

@andy778 andy778 commented Nov 28, 2026

Copy link
Copy Markdown
Owner

Summary

  • Applies fraatti's bridge.diff from Radio command interface, frame-format corrections, pairing, alarm counters and process logic (from the MC9S08 firmware) #113: the HA bridge's single msg_state binary_sensor couldn't represent five independent alarm types and expire_after hid a still-active alarm after ~150s. Now one retained problem binary_sensor per alarm type, plus a separate "Radio Link" connectivity sensor fed by every frame (no expiry on alarm sensors). Also fixes the systemd install copying the wrapper script without rtl_433_mqtt_hass_uclean1.py next to it, which crash-looped the service every 10s.
  • Corrects docs/eeprom-map.md, docs/ghidra/codes.md, docs/u2-serial-protocol.md: Proc Ver 30's Test cycle (firmware-confirmed from the board-A flash dump) runs 6 steps (S401–S406: pump-in/sludge-removal/pump-out/chem-fill/dose/aeration), not the installation manual's 8, and ends by starting a full cleaning batch rather than returning to the counter display.

Test plan

  • Confirmed the production rtl433-uclean1.service's /usr/local/bin/rtl_433 binary has no uponor_clean1 decoder registered at all (built 2026-05-18, predates the decoder) — service was running blind. Not fixed here; flagged for the user to rebuild/replace that binary separately.
  • Built the andy778/rtl_433 fork (add-uponor-clean1-upstream) locally; confirmed decoder is registered (-R help lists [387] Uponor Clean 1).
  • Live 90s capture with an RTL-SDR dongle against the real unit: heartbeat + ACK pairs decode correctly with the patched node-ID order.
  • Smoke-tested the patched bridge's new functions (bridge_alarm, bridge_link, clear_legacy_entities, alarm_mapping) against a stub MQTT client: per-type retained publish, link sensor has no expire_after, legacy -fault entity cleared once per device.
  • python3 -m py_compile passes.
  • Not tested against a live Home Assistant instance (same caveat fraatti noted).

…cle is 6 steps

The HA bridge used one shared msg_state binary_sensor, so only the
last-changed alarm type was reflected and expire_after hid any alarm
still active after ~150s. Split into one retained binary_sensor per
alarm type plus a separate Radio Link connectivity sensor fed by every
frame, with no expiry on the alarm sensors. Also fixes the systemd
install copying the wrapper without the bridge script next to it,
which crash-looped the service.

Also corrects docs/eeprom-map.md, docs/ghidra/codes.md and
docs/u2-serial-protocol.md: Proc Ver 30's Test cycle runs 6 steps
(S401-S406), not the manual's 8 -- firmware-confirmed, and it starts a
full cleaning batch afterward instead of returning to the counter
display.

Patch and analysis from fraatti in #113.
Unrelated version skew on main (fixed, unmerged, on
ci/fix-codeql-action-version-skew) broke CodeQL on this branch too.
@andy778
andy778 merged commit 317aef3 into main Nov 28, 2026
4 checks passed
@andy778
andy778 deleted the fix/issue-113-bridge-and-testcycle-docs branch November 28, 2026 11: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.

1 participant