Skip to content

test(trace): add authentic MyHomeServer1 WHO 25 scenario plus trace and replay test (#466) - #673

Merged
GreenGrassBlueOcean merged 1 commit into
OpenWebNet-HA:v2-phase1-architecturefrom
GreenGrassBlueOcean:test/issue-466-myhomeserver1-scenarioplus-trace
Oct 9, 2026
Merged

GreenGrassBlueOcean merged 1 commit into
OpenWebNet-HA:v2-phase1-architecturefrom
GreenGrassBlueOcean:test/issue-466-myhomeserver1-scenarioplus-trace

Conversation

@GreenGrassBlueOcean

@GreenGrassBlueOcean GreenGrassBlueOcean commented Oct 9, 2026 •

Copy link
Copy Markdown
Contributor

Summary

Authentic on-wire bus trace captured from a physical BTicino MyHomeServer1 gateway (FW 2.87.13), closing the hardware verification gap for WHO 25 Scheduled Scenario PLUS (*25*11#0*WHERE##).

Contributed by @TheDarkWizard on issue #466 (comment 6085724930) in response to the community call-out for real-world WHO 25 scenario plus traces (#466 (comment 6085158753)).


1. What is the problem?

Under project testing policy, new protocol features and subsystem implementations cannot be merged based solely on firmware emulator analysis or reverse engineering—they strictly require verified on-wire bus frames from a physical customer installation in tests/fixtures/traces/.

Both OpenWebNet-HA/OWNd#91 (feat(cen): parse and build WHO 25 scenario-plus frames (WHAT 11-15)) and OpenWebNet-HA/MyHOME#671 (feat(cenplus): support WHO 25 Scenario Plus commands and events) were blocked awaiting physical hardware traces confirming:

  1. That a physical gateway accepts *25*11#0*WHERE## on its command session.
  2. That the gateway translates the command to the physical SCS bus (opcode B1 01 93 00).
  3. That the gateway emits an event echo (*25*11#0*WHERE##) on the OpenWebNet monitor session.

2. How is it solved?

  1. Trace Capture Fixture (tests/fixtures/traces/issue_466/config_entry-myhome_MyHomeServer1_who25_scenario_plus.json):
    • Ingested the authentic 500-frame diagnostic download from @TheDarkWizard's live plant.
    • Privacy-sanitized: verified 0 personal data leaks via scripts/anonymize_plant_fixture.py --check.
  2. Provenance Documentation (tests/fixtures/traces/issue_466/README.md):
    • Added hardware profile (BTicino MyHomeServer1, FW 2.87.13, TCP port 20000).
    • Documented contributed file manifest and detailed chronological breakdown of recorded actions.
  3. Deterministic Replay Test (tests/test_issue_466_myhomeserver1_scenarioplus_trace.py):
    • Implemented an async test that replays all 500 frames through the gateway event bus and dispatcher without exceptions.
    • Specifically validates grammar and semantics for WHO 25 scenario plus, WHO 18 active power measurements, WHO 4 climate telemetry, and WHO 1 lights.

3. How is it tested?

  1. Deterministic Trace Replay:
    • test_myhomeserver1_scenarioplus_trace_replay_without_exceptions: Replays all 500 on-wire frames through the gateway dispatcher into Home Assistant without any errors or unhandled exceptions.
    • test_myhomeserver1_scenarioplus_specific_frame_grammar: Validates parsing of *25*11#0*11##, *#18*51*113*2343##, *#4*2*60*49##, and *1*0*0014##.
  2. Quality & Standard Gates:
    • All 100 tests in tests/test_issue_466* passing in WSL.
    • Ruff linting: 0 violations.
    • Architectural validator (scripts/verify_ha_standards.py): 54/54 rules satisfied.
    • Anti-drift sentinel (scripts/sync_documentation.py --check): 0 drift detected.

4. Where are the traces?

  1. Trace Files in Tree:

    • tests/fixtures/traces/issue_466/config_entry-myhome_MyHomeServer1_who25_scenario_plus.json (originally attached as Cen&Cen+CallToAction.json on #466 (comment 6085724930)).
    • Documented in tests/fixtures/traces/issue_466/README.md.
  2. On-Wire Evidence:

    • [tx] *25*11#0*11## (2026-10-09T17:14:12.215385+00:00): Scenario Plus ON command sent to physical gateway.
    • [rx] *25*11#0*11## (2026-10-09T17:14:12.298174+00:00): Acknowledged and placed on physical SCS bus (translating to bus opcode B1 01 93 00), echoing back on monitor session 82.8 ms later.
    • Gateway status request: [tx] *#25*11## (2026-10-09T17:14:12.300230+00:00).
    • Protocol confirmation on OFF: User also attempted [tx] *25*12#0*11##. Because in OpenWebNet and bt_luci OFF takes no #0 parameter (*25*12*WHERE##), the gateway did not echo 12#0, confirming the exact grammar distinctions implemented in OWNd#91.

Co-authored-by: TheDarkWizard 9061870+TheDarkWizard@users.noreply.github.com

…nd replay test (OpenWebNet-HA#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 (OpenWebNet-HA#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 OpenWebNet-HA#671.

Co-authored-by: TheDarkWizard <9061870+TheDarkWizard@users.noreply.github.com>
@codecov-commenter

Copy link
Copy Markdown

⚠️ Please install the 'codecov app svg image' to ensure uploads and comments are reliably processed by Codecov.

Codecov Report

✅ All modified and coverable lines are covered by tests.

📢 Thoughts on this report? Let us know!

@GreenGrassBlueOcean
GreenGrassBlueOcean merged commit 0433228 into OpenWebNet-HA:v2-phase1-architecture Oct 9, 2026
16 checks passed
@GreenGrassBlueOcean
GreenGrassBlueOcean deleted the test/issue-466-myhomeserver1-scenarioplus-trace branch October 9, 2026 17:36
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.

2 participants