Conversation
There was a problem hiding this comment.
Pull request overview
Updates the SolisCloud integration to better align reserve/min-SoC behavior and Home Assistant switch state conventions, plus bumps the Predbat version.
Changes:
- Adjust SolisCloud auto-configuration to use
reserve_socasbattery_min_soc. - Publish SolisCloud switch entities using
on/offstates instead of1/0. - Bump Predbat version to
v8.34.13.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
| apps/predbat/solis.py | Updates SolisCloud auto-config reserve/min-SoC mapping and normalizes published switch states to HA conventions. |
| apps/predbat/predbat.py | Version bump reflecting the Solis changes. |
| #self.set_arg("soc_max", [f"sensor.{self.prefix}_solis_{device}_battery_capacity" for device in devices]) | ||
|
|
||
| # Reserve and limits | ||
| # Reserve isn't writable (so we don't use it for SolisCloud) instead we use it as the min SOC |
There was a problem hiding this comment.
The new comment says the reserve SOC “isn't writable”, but this integration does support writing reserve_soc via number_event (it maps reserve_soc to SOLIS_CID_BATTERY_RESERVE_SOC and calls read_and_write_cid). This makes the comment misleading for future maintainers.
Consider rewording to clarify that Predbat's core reserve functionality is disabled for SolisCloud (see INVERTER_DEF["SolisCloud"]["has_reserve_soc"] == False), and that reserve_soc is being reused as battery_min_soc for planning purposes (or remove the “isn't writable” claim).
| # Reserve isn't writable (so we don't use it for SolisCloud) instead we use it as the min SOC | |
| # Predbat core reserve is disabled for SolisCloud; reuse reserve_soc as battery_min_soc for planning instead |
No description provided.