Repository navigation
feat(cenplus): support WHO 25 Scenario Plus commands and events - #671
Merged
GreenGrassBlueOcean merged 7 commits intoOct 9, 2026
Conversation
Contributor
Author
📡 Physical Plant Trace Captured & Verified — PR #671 Unblocked! 🎉We are pleased to report that the required real-world hardware verification has been contributed and integrated into our test corpus:
Evidence Breakdown:
With the authentic physical trace permanently locked in CI and all architectural validators satisfied, this PR is now fully unblocked! 🚀 |
GreenGrassBlueOcean
added a commit
that referenced
this pull request
Oct 9, 2026
…nd replay test (#466) Captured from a physical BTicino MyHomeServer1 gateway (FW 2.87.13) by @TheDarkWizard on 2026-10-09 in response to the community call for real-world WHO 25 scenario plus traces (#466). Validates gateway acceptance, SCS bus relay, and OpenWebNet monitor echo of Scheduled Scenario PLUS frame *25*11#0*11## (~82.8 ms RTT), unblocking OpenWebNet-HA/OWNd#91 and #671. Co-authored-by: TheDarkWizard <9061870+TheDarkWizard@users.noreply.github.com>
|
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
…fix event fallback inheritance
… suppression on who25
…ario plus command
…calls and add exception translations
GreenGrassBlueOcean
force-pushed
the
feat/who25-scenario-plus
branch
from
October 9, 2026 19:49
128b6c3 to
7500204
Compare
GreenGrassBlueOcean
force-pushed
the
feat/who25-scenario-plus
branch
from
October 9, 2026 19:55
7500204 to
ed293ed
Compare
GreenGrassBlueOcean
merged commit Oct 9, 2026
d548939
into
OpenWebNet-HA:v2-phase1-architecture
16 checks passed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Note
PHYSICAL TRACE VERIFIED: Unblocked by authentic physical plant trace contributed by @TheDarkWizard in #466 (comment 6085724930) and added in PR #673.
Summary
Companion PR to OpenWebNet-HA/OWNd#91.
Implements support for WHO 25 Scenario Plus commands and events (
WHAT 11–15:on,off,increase,decrease,stop), consumingOWNScenarioPlusEventfor bus event dispatching and device registry auto-registration, and exposing themyhome.send_scenario_plus_commandservice.1. What is the problem?
In Legrand / BTicino MyHOME installations,
WHO 25is primarily known for CEN+ button push/release/held actions (WHAT 21..28) and dry contact / IR events (WHAT 31..32). However, scenario programmers and touch screens (such as the MH200, MH200N, MH202, MyHomeServer1, and 10" / 3.5" Touch Screens running Legrand'slibqtdevicesTS10 firmware) also utilize WHO 25 for Scheduled Scenario PLUS control:WHAT = 11#0(turn_on)WHAT = 12(turn_off)WHAT = 13#0#5(increase)WHAT = 14#0#5(decrease)WHAT = 15(stop)Prior to OpenWebNet-HA/OWNd#91, these frames were parsed as generic bare
OWNEventorOWNCommandframes without type information, action parsing, or factory builders.In
MyHOME, there was no integration-level support to:OWNScenarioPlusEvent), dispatch them to Home Assistant's event bus, and automatically discover/register the scenario device in the Home Assistant Device Registry.on,off,increase,decrease,stop) to an addressed scenario plus unit on the SCS bus.2. How is it solved?
Event Dispatching & Auto-Registration (
custom_components/myhome/gateway_events.py):OWNScenarioPlusEventinMyHOMEGatewayEvents.handle_raw_event().myhome_scenario_plus_eventonhass.busand via per-gateway dispatchermyhome_scenario_plus_event_<MAC>with payload containingobject,action,where,gateway_mac, andentry_id.self.handler._ensure_cen_device(25, raw_obj)to auto-register the scenario plus unit under its gateway in the Home Assistant Device Registry as aCEN+ Scenario Control.Custom Service
myhome.send_scenario_plus_command(custom_components/myhome/services.py):myhome.send_scenario_plus_commandwith required parameterswhereandaction(on,off,increase,decrease,stop) and optionalgateway(targeting specific gateway MAC or defaulting to primary).OWNScenarioPlusCommandclassmethods (turn_on,turn_off,increase,decrease,stop) with clean string fallback to safely construct and transmit the OpenWebNet frames.custom_components/myhome/services.yamlwith selectors, UI labels, and descriptions incustom_components/myhome/strings.jsonandtranslations/en.json.Documentation Alignment & Anti-Drift:
docs/configuration/services.mdwith descriptions, parameter tables, and YAML automations examples.docs/configuration/cen_cenplus.mdprotocol table to include Scenario Plus frame syntax.scripts/sync_documentation.py --check).3. How is it tested?
Service Unit Testing (
tests/test_services.py):test_send_scenario_plus_command_service: Validates sending all 5 actions (on->*25*11#0*11##,off->*25*12*11##,increase->*25*13#0#5*11##,decrease->*25*14#0#5*11##,stop->*25*15*11##), invalid action rejection, missing gateway fallback, and missing where validation.Gateway Event & Auto-Registration Testing (
tests/test_gateway.py):test_gateway_scenarioplus_event_and_auto_registration: Validates listening loop receivingOWNScenarioPlusEvent, firingmyhome_scenario_plus_eventwith expected payload, and auto-registering the scenario device with device registry identifiers(DOMAIN, f"{mac}-25-{where}")attached via gateway device ID.Full Quality Verification:
test_services.pyandtest_gateway.pypassing cleanly.scripts/verify_ha_standards.py).custom_components,tests,docs.scripts/sync_documentation.py --check).4. Where are the traces?
Authentic Physical Plant Trace Captured & Verified in PR test(trace): add authentic MyHomeServer1 WHO 25 scenario plus trace and replay test (#466) #673:
tests/fixtures/traces/issue_466/config_entry-myhome_MyHomeServer1_who25_scenario_plus.json).tests/test_issue_466_myhomeserver1_scenarioplus_trace.py(500/500 frames replayed through Home Assistant event dispatcher without exceptions).On-Wire Evidence:
[tx] *25*11#0*11##(2026-10-09T17:14:12.215385+00:00) sent viamyhome.send_message.[rx] *25*11#0*11##(2026-10-09T17:14:12.298174+00:00) received on the OpenWebNet monitor session 82.8 ms later.*25*11#0*11##, puts opcodeB1 01 93 00on the physical SCS bus, and echoes it back to OpenWebNet monitoring sessions.[tx] *25*12#0*11##was not echoed because OFF takes no#0parameter (*25*12*WHERE##), matching the exact grammar implemented in OWNd#91.Theoretical / Protocol Background:
libqtdevicestagTS10_1_0_23(scenario_device.cpp:36-41):own-firmware-oracle(MH202010024, MHS1028206) confirm translator mapping to SCS opcodes 93–97.