EV-03: car charger seam, Alfen HA driver, read-only Car card
Read-only: nothing in this change writes to the charger. - app/chargers.py: ChargerDriver, AlfenHaDriver, UnavailableCharger, ChargerReading, CarTracker - options ev_charger/ev_current_entity/ev_max_a/ev_phases (default off), Settings group, validator, census - Car card on Home, unreachable row and notification, two-writer info row, MQTT sensors - car out of the House tile and the house profile - tools/chargersim.py charger model, test_ev03.py Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
@@ -139,6 +139,11 @@ SENSORS = [
|
||||
# a charge-power limit, or the optimiser declining to charge.
|
||||
OPTIONAL_SENSORS = [
|
||||
("pv", "goodwe_pv_power", "PV power", "W", "power", "measurement", None),
|
||||
# EV-03: only with a car charger switched on. Read only: there are no
|
||||
# command entities in this version.
|
||||
("car_power", "goodwe_car_power", "Car power", "W", "power", "measurement", "mdi:car-electric"),
|
||||
("car_state", "goodwe_car_state", "Car state", None, None, None, "mdi:ev-station"),
|
||||
("car_today_kwh", "goodwe_car_today_kwh", "Car energy today", "kWh", "energy", "total_increasing", "mdi:ev-station"),
|
||||
]
|
||||
|
||||
# ⚠️ HA's OWN "this sensor has no value" PAYLOAD, and the one place this add-on
|
||||
@@ -192,7 +197,11 @@ def optional_keys(opts: dict) -> tuple:
|
||||
# `_load()` is the same decision for the same kind of reason. Measured, not
|
||||
# assumed: move this line to module scope and test_mqtt.py part 8 dies.
|
||||
from . import pv as _pv
|
||||
return ("pv",) if _pv.entities(opts) else ()
|
||||
from . import chargers as _ch # EV-03: same reason
|
||||
out = ("pv",) if _pv.entities(opts) else ()
|
||||
if _ch.census_entity(opts):
|
||||
out += ("car_power", "car_state", "car_today_kwh")
|
||||
return out
|
||||
|
||||
|
||||
BASE = "goodwe_ctl"
|
||||
|
||||
Reference in New Issue
Block a user