EV-03: car charger seam, Alfen HA driver, read-only Car card
checks / unit (pull_request) Failing after 37m42s
infra-pin / fresh (pull_request) Successful in 2s

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:
ev03-dev
2026-11-15 09:52:15 +01:00
co-authored by Claude
parent 6bf37597f8
commit 89a2eb0b74
30 changed files with 2656 additions and 23 deletions
+13 -1
View File
@@ -82,7 +82,7 @@ import os
import aiohttp
from . import messages
from . import chargers, messages
from .configui import changed_keys
from .inverter import build_roster
from .validate import validate_startup_config, validate_unit_ranges
@@ -362,6 +362,18 @@ async def problems_and_ranges(opts: dict, hass=None, notes=None):
unread = [unit.driver.actuator_id() for unit in units
if unit.driver.configured() and unit.dev_min is None
and unit.dev_max is None]
# EV-03: the charger limit may not exceed the station limit the charger
# reports. A read only; a charger that does not answer skips the check.
if hass is not None and chargers.mode_of(opts) != chargers.OFF:
drv = chargers.build(opts)
if drv.configured():
_lo, station, _ph = await drv.bind(hass).limits()
amps = chargers.max_a(opts)
if station is not None and amps is not None and amps > station:
problems.append(
f"{messages.setting('ev_max_a')} is {amps:.0f} A, but the "
f"charger allows at most {station:.0f} A. Lower it to "
f"{station:.0f} A or less.")
return problems, unread