Skip to content

Commit b8cc742

Browse files
author
Maksym Shtembuliak
committed
feat: add document-backed SMG write profiles
1 parent 871e18e commit b8cc742

40 files changed

Lines changed: 1896 additions & 102 deletions

‎CHANGELOG.md‎

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,11 @@ the GitHub release body should be rendered from the matching version section her
99

1010
### Added
1111

12+
- Added version-specific, document-backed write profiles for Anenji
13+
Communication Protocol No. 3-10 variants 3, 4, 5, and 6. The exact HHS-11kW
14+
Protocol 3 fingerprint can now opt into its documented controls through Full
15+
Control; all new controls remain untested, and destructive reset/counter-clear
16+
operations stay blocked.
1217
- Added built-in detection and telemetry mapping for the Sandisolar SD 11KP48V
1318
WIFI fingerprint (`layout=4`, `model=0x8003`) from issue #13 evidence.
1419
Its two hardware-confirmed Secondary Priority controls are available normally;
@@ -22,6 +27,12 @@ the GitHub release body should be rendered from the matching version section her
2227

2328
### Changed
2429

30+
- Replaced the ambiguous writable `modbus_smg/base.json` profile with one
31+
explicit, document-backed classic SMG RS232 V1 map shared by compatible
32+
layout 1/2/11 model profiles. Exact hardware overlays retain their existing
33+
tested controls and model-only registers, while unknown SMG fingerprints
34+
remain read-only. The V1 document version is no longer presented as proof
35+
that register 184 must contain protocol number 1.
2536
- Rebuilt the Anenji Protocol No. 3-10 telemetry layer as one documented shared
2637
schema with separate Protocol 3 and Protocol 4 output projections. ANJ-11KW,
2738
HHS-11kW and Sandisolar fingerprints now select registers by protocol identity,

‎catalog/inverter_models/models/anenji_4200_protocol_1.json‎

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,9 +28,9 @@
2828
"coverage": {
2929
"runtime_control_surface": "device_scoped_overlay",
3030
"smartess_control_surface": "device_scoped_overlay",
31-
"vendor_register_map": "unknown",
31+
"vendor_register_map": "documented",
3232
"notes": [
33-
"Base runtime profile exposes the standard ANJ-4200/SMG Protocol 1 surface.",
33+
"The common runtime surface comes from the documented classic SMG RS232 V1 map; the observed register-184 value 1 is separate runtime identity evidence.",
3434
"Full cloud shadow-learning correlated 77 cloud write attempts and activated eight device-scoped learned controls; writes were captured but intentionally not applied."
3535
]
3636
},
@@ -40,6 +40,7 @@
4040
],
4141
"knowledge_summary": "Anenji 4200 Protocol 1 variant has user support captures from an ANJ-4000W-24V device. Runtime detection resolves exactly to the SMG Protocol 1 surface, read telemetry is confirmed, and a full shadow-learning run mapped the SmartESS 0925 write surface without leaking writes to the real inverter. Treat controls as partial until specific Home Assistant writes are user-validated.",
4242
"source_keys": [
43+
"documentation_classic_smg_rs232_v1",
4344
"note_anenji_4200_rule_migration",
4445
"github_issue_9",
4546
"support_archive_issue_9_20260619",

‎catalog/inverter_models/models/anenji_6200_single_output.json‎

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,16 +25,17 @@
2525
"coverage": {
2626
"runtime_control_surface": "available",
2727
"smartess_control_surface": "unknown",
28-
"vendor_register_map": "unknown",
28+
"vendor_register_map": "documented",
2929
"notes": [
30-
"Runtime write surface is inherited from the shared SMG base profile; not every write is independently validated on this commercial unit."
30+
"Runtime writes inherit the documented classic SMG RS232 V1 surface; not every write is independently validated on this commercial unit."
3131
]
3232
},
3333
"known_limitations": [
3434
"Controls inherit the SMG 6200 control set; not every writable setting is independently confirmed on this unit."
3535
],
3636
"knowledge_summary": "Anenji single-output 6200 (layout 1) bound to the shared SMG base surface; same control set as the verified SMG 6200.",
3737
"source_keys": [
38+
"documentation_classic_smg_rs232_v1",
3839
"corpus_anenji_6200_single"
3940
]
4041
}

‎catalog/inverter_models/models/anenji_anj_6200_48pl.json‎

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,16 +23,17 @@
2323
"coverage": {
2424
"runtime_control_surface": "available",
2525
"smartess_control_surface": "unknown",
26-
"vendor_register_map": "unknown",
26+
"vendor_register_map": "documented",
2727
"notes": [
28-
"Runtime write surface is shared with SMG 6200; write behavior is not independently confirmed on this commercial unit."
28+
"Runtime writes use the documented classic SMG RS232 V1 surface plus the SMG 6200 model overlay; write behavior is not independently confirmed on this commercial unit."
2929
]
3030
},
3131
"known_limitations": [
3232
"Shares the SMG 6200 runtime surface; writes are not independently hardware-confirmed on this unit."
3333
],
3434
"knowledge_summary": "SMG layout 2 model that reuses the SMG 6200 runtime surface; reported via a GitHub issue and a support capture.",
3535
"source_keys": [
36+
"documentation_classic_smg_rs232_v1",
3637
"github_issue_8",
3738
"support_archive_anj6200_48pl"
3839
]

‎catalog/inverter_models/models/anenji_hhs_11kw_wifi_no_parallel.json‎

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -18,25 +18,27 @@
1818
"validation": {
1919
"hardware": "captured",
2020
"telemetry": "partial",
21-
"controls": "none"
21+
"controls": "partial"
2222
},
2323
"coverage": {
24-
"runtime_control_surface": "read_only",
24+
"runtime_control_surface": "available",
2525
"smartess_control_surface": "unknown",
2626
"vendor_register_map": "documented",
2727
"notes": [
2828
"The exact layout/model fingerprint is captured from a beta.3 support archive.",
29-
"The protocol-3 telemetry projection is enabled read-only.",
29+
"The exact fingerprint uses the documented Protocol 3 telemetry and write matrices.",
3030
"A later proxy capture and matching DESSMonitor export confirmed the documented L1 Grid Power at holding register 340 for this exact fingerprint.",
31-
"No ANJ-11KW writable capability is inherited until this exact HHS model is write-validated."
31+
"Documented Protocol 3 controls are available only after the user explicitly selects Full Control; none is marked hardware-tested on this model.",
32+
"Registers whose protocol-number column is empty, and Protocol 4/6-only OP2 controls, are not inherited."
3233
]
3334
},
3435
"known_limitations": [
35-
"Local controls remain unavailable pending model-specific hardware validation."
36+
"No local write has been hardware-validated on this exact model; Auto mode remains read-only and the documented controls are experimental Full-Control candidates."
3637
],
37-
"knowledge_summary": "An Anenji HHS 11kW non-parallel inverter with an exact captured protocol-3 fingerprint. The integration exposes the shared protocol-3 telemetry projection read-only, including hardware-correlated Grid Power, and deliberately withholds ANJ write controls.",
38+
"knowledge_summary": "An Anenji HHS 11kW non-parallel inverter with an exact captured Protocol 3 fingerprint. The integration exposes the shared telemetry projection, including hardware-correlated Grid Power, and offers only the controls explicitly valid for Protocol 3 as untested Full-Control candidates.",
3839
"source_keys": [
3940
"github_issue_13_hhs_11kw_beta3",
40-
"github_issue_13_hhs_grid_power_20260827"
41+
"github_issue_13_hhs_grid_power_20260827",
42+
"documentation_anenji_protocol_3_10"
4143
]
4244
}

‎catalog/inverter_models/models/aninerel_6200_dual_output.json‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,7 @@
4444
],
4545
"knowledge_summary": "Aninerel dual-output 6200 / Aninerel 6.2KW resolves to the OP2 6200 runtime surface (layout 11, model code 30979, rated 6200, firmware 7903_A6260126v1). The aninerel.zip donor capture and the issue #7 support package are treated as the same shared OP2 model family unless a future stable runtime anchor proves otherwise. Owner ESPHome YAML and shadow-learning evidence extend the known Modbus register map for this family.",
4646
"source_keys": [
47+
"documentation_classic_smg_rs232_v1",
4748
"github_issue_7",
4849
"corpus_aninerel_op2_6200",
4950
"private_message_op2_registers",

‎catalog/inverter_models/models/aninerel_anl_4200t_24l_w_pro.json‎

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,9 +23,9 @@
2323
"coverage": {
2424
"runtime_control_surface": "available",
2525
"smartess_control_surface": "cloud_catalog",
26-
"vendor_register_map": "unknown",
26+
"vendor_register_map": "documented",
2727
"notes": [
28-
"Binds a model-specific full-control surface (no longer the read-only family fallback). The family-proven SMG control set ships tested (visible in the default control mode); the family's unverified extras stay untested (full-control only).",
28+
"Binds a model-specific full-control surface over the documented classic SMG RS232 V1 map (no longer the read-only family fallback). Hardware-tested controls are visible in the default control mode; unverified controls stay full-control only.",
2929
"A tester confirmed writes on hardware (2026-07-05); battery-voltage setpoint windows are left wide because this is a 24 V unit and the family templates carry 48 V-class windows, so the inverter's own write validation is the authority."
3030
]
3131
},
@@ -35,6 +35,7 @@
3535
],
3636
"knowledge_summary": "Aninerel ANL-4200T-24L-W-PRO reported via GitHub issue #3 and donor captures. It resolves exactly (SMG layout code 11) and binds a model-specific full-control surface: the family-proven SMG settings (output/charge source priority, battery voltage windows, charge-current limits, buzzer/LCD/input mode, boot mode) ship tested and a tester confirmed writes on hardware; the family's unverified extras (exit-fault action, output-rating/mode, power-saving, overload-bypass, remote turn-on/shutdown) stay untested and appear only in full control.",
3737
"source_keys": [
38+
"documentation_classic_smg_rs232_v1",
3839
"github_issue_3",
3940
"corpus_aninerel_anl_4200t"
4041
]

‎catalog/inverter_models/models/sandisolar_sd_hym_4862hwp.json‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,7 @@
3333
"known_limitations": [],
3434
"knowledge_summary": "Maintainer's Sandisolar SD-HYM-4862HWP resolves to runtime descriptor smg_6200 via local SMG identity anchors: register 171 device_type/model_code=0x1E00 (7680), register 184 protocol/layout=1, and register 643 rated_power=6200. The local SMG register set does not expose the commercial model name, so the Sandisolar mapping is hardware/source-backed rather than register-name-backed. Full telemetry, the original SMG control set, and five cloud shadow-learning controls (304, 322, 330, 338, 425) are validated on this hardware; destructive actions 460 and 461 remain excluded.",
3535
"source_keys": [
36+
"documentation_classic_smg_rs232_v1",
3637
"maintainer_sandisolar_sd_hym_4862hwp_hardware",
3738
"support_archive_sandisolar_shadow_learning_20260618"
3839
]
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
{
2+
"schema_version": 1,
3+
"source_key": "documentation_classic_smg_rs232_v1",
4+
"kind": "documentation",
5+
"title": "Classic SMG Modbus RTU RS232 protocol V1.0",
6+
"reference": "https://github.com/syssi/esphome-smg-ii/blob/main/docs/SMG-RS232%2BCommunication%2BProtocol%2BV1.0.1.pdf",
7+
"captured_at": "2026-08-30",
8+
"visibility": "public",
9+
"summary_publishable": true,
10+
"summary": "Public copy of the November 2021 classic SMG Modbus RTU RS232 register document. It defines the shared telemetry and writable configuration map used by the classic SMG runtime family. The document calls register 184 invalid data, so observed values 1, 2, and 11 remain runtime layout evidence rather than being inferred from the document version.",
11+
"assertions": [
12+
"register_map",
13+
"runtime_compatibility"
14+
]
15+
}

‎custom_components/eybond_local/control_policy.py‎

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -107,6 +107,8 @@ def can_expose_capability(
107107
) -> bool:
108108
"""Return whether a capability should be exposed as a control entity."""
109109

110+
if capability.resolved_support_tier == "blocked":
111+
return False
110112
if control_mode == CONTROL_MODE_FULL:
111113
return True
112114
if control_mode == CONTROL_MODE_READ_ONLY:
@@ -125,6 +127,10 @@ def can_expose_preset(
125127
) -> bool:
126128
"""Return whether a preset should be exposed as a control entity."""
127129

130+
for item in preset.items:
131+
capability = capabilities_by_key.get(item.capability_key)
132+
if capability is None or capability.resolved_support_tier == "blocked":
133+
return False
128134
if control_mode == CONTROL_MODE_FULL:
129135
return True
130136
if control_mode == CONTROL_MODE_READ_ONLY:

0 commit comments

Comments
 (0)