mirror of
https://github.com/NickoScope/nickol-knx-mcp.git
synced 2026-09-29 19:31:12 +02:00
generate_ha: a command GA the actuator reports on is its own state address
Found on a real 1312-GA house (43 of 159 "switch without status" had a Read+Transmit object on the command GA), measured on all seven corpus projects. detect_missing_status already counted these as satisfied through pairing.self_reporting(); the generator did not and put them on the review list without a state_address. It now uses the same function: no separate status found and the command GA has an R+T object -> state_address = the command GA. Same for the on/off sibling of a dimmable light and for brightness_state_address on a self-reporting brightness GA. Write-only objects still go to review. Corpus: no entity count changed, no address lost; review items 598 -> 555 on the house, -36, -40, -12, -1, -32 on the others. Test C in test_real_house_fixes.py covers R+T, write-only and a non-lighting switch. Not verified on a live Home Assistant: state_address equal to address is accepted by the KNX schema and xknx reads from it, but no running instance was used here. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Opus 5
parent
3968ce2cde
commit
76249469bb
@@ -20,6 +20,13 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
||||
and 14.031, and power factor has its own rule (14.057). Checked against xknx 3.20. On a real
|
||||
1312-GA house: 17 findings -> 2.
|
||||
|
||||
- **Self-reporting commands get their state address.** When the actuator's status object (Read +
|
||||
Transmit flags) is linked to the command GA itself, there is no separate status GA to find. The
|
||||
generator now uses the command GA as `state_address` (and the brightness GA as
|
||||
`brightness_state_address`) instead of reporting a missing status. `check_missing_status` already
|
||||
treated these as satisfied; the two now agree. On a real house 43 fewer review items, 40 to 44
|
||||
entities per large project gain a state address, and no entity count changes.
|
||||
|
||||
### Changed
|
||||
|
||||
- **On/off lighting is generated as a Home Assistant `light`, not a `switch`.** The KNX light platform
|
||||
|
||||
Reference in New Issue
Block a user