Commit 182894c
committed
fix: isolate EVC second register segment; dynamic max from 0x64F
SolaX support (ticket 703158) confirmed the EVC holding registers are
internally segmented: 0x600-0x650 is one segment, 0x660-0x66F another
(mainly internal master-slave parallel operation). A function 0x03 read
that spans the boundary silently returns 0 for second-segment registers.
Reproduced on an X3-EVC-11kW Gen1 (ARM v1.18): reading 0x640 count 48
returns 0 for 0x668 (Max Charge Current), while an in-segment or single
read returns the true value.
Starting a new read block at 0x668 pins the segment boundary, so the
0x668/0x669 block never crosses it. That makes the block_size=32
workaround (introduced blind against this same symptom before the
segmentation was known) unnecessary, so the plugin returns to the
default 100. Both resulting holding blocks verified on the charger
above against single-register reads.
Support pointed to the documented register 0x64F (limit_current_allmode).
Live testing shows it is the persistent maximum limit, not the setpoint:
SolaXCloud writes the active setpoint through 0x668 (0x64F stays fixed
at the device rating, and external writes to 0x64F are acknowledged but
ignored), and the cloud UI caps its picker at the 0x64F value. The Max
Charge Current entity therefore stays on 0x668 and now reads 0x64F as a
readback sensor to cap its own slider the same way, via a new optional
max_key field on number descriptions that dynamically overrides
native_max_value from a sensor value, falling back to the static
native_max_value when absent.1 parent 36c01e0 commit 182894c
3 files changed
Lines changed: 21 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
390 | 390 | | |
391 | 391 | | |
392 | 392 | | |
| 393 | + | |
393 | 394 | | |
394 | 395 | | |
395 | 396 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
184 | 184 | | |
185 | 185 | | |
186 | 186 | | |
| 187 | + | |
| 188 | + | |
| 189 | + | |
| 190 | + | |
| 191 | + | |
| 192 | + | |
| 193 | + | |
| 194 | + | |
| 195 | + | |
187 | 196 | | |
188 | 197 | | |
189 | 198 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
322 | 322 | | |
323 | 323 | | |
324 | 324 | | |
| 325 | + | |
325 | 326 | | |
326 | 327 | | |
327 | 328 | | |
| |||
737 | 738 | | |
738 | 739 | | |
739 | 740 | | |
| 741 | + | |
| 742 | + | |
| 743 | + | |
| 744 | + | |
| 745 | + | |
| 746 | + | |
| 747 | + | |
| 748 | + | |
740 | 749 | | |
741 | 750 | | |
742 | 751 | | |
743 | 752 | | |
| 753 | + | |
744 | 754 | | |
745 | 755 | | |
746 | 756 | | |
| |||
1764 | 1774 | | |
1765 | 1775 | | |
1766 | 1776 | | |
1767 | | - | |
| 1777 | + | |
1768 | 1778 | | |
1769 | 1779 | | |
1770 | 1780 | | |
0 commit comments