From 0e6f5fc5102747fe02da0422747a2c452614795f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gints=20Kir=C5=A1teins?= Date: Mon, 6 Apr 2026 21:13:41 +0300 Subject: [PATCH] =?UTF-8?q?Fix=20dashboard=20cards=20=E2=80=94=20split=20i?= =?UTF-8?q?nto=203=20usable=20blocks,=20remove=20broken=20templates?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-Authored-By: Claude Sonnet 4.6 --- dashboard_card.yaml | 71 +++++++++++++++++++++++---------------------- 1 file changed, 36 insertions(+), 35 deletions(-) diff --git a/dashboard_card.yaml b/dashboard_card.yaml index a1f4888..9e43c96 100644 --- a/dashboard_card.yaml +++ b/dashboard_card.yaml @@ -1,45 +1,48 @@ -# EMHASS Dashboard Card -# Add this to your dashboard (Dashboard → Edit → Add Card → Manual) +# EMHASS Dashboard Cards +# These are 3 separate cards — add each block individually: +# Dashboard → Edit → Add Card → Manual → paste one block at a time +# ─── CARD 1: EMHASS Energy Status ──────────────────────────────────────────── type: entities title: EMHASS Energy Status show_header_toggle: false entities: - # Current Status - type: section label: Current Status - entity: sensor.current_hour_price name: Current Price icon: mdi:cash - secondary_info: "{{ state_attr('sensor.nordpool_kwh_lv_eur_3_10_021', 'low_price') }}" - entity: sensor.battery_power_state name: Battery State - icon: > - {% if is_state('sensor.battery_power_state', 'charging') %}mdi:battery-charging - {% elif is_state('sensor.battery_power_state', 'discharging') %}mdi:battery-minus - {% else %}mdi:battery{% endif %} + icon: mdi:battery - entity: sensor.deye_inverter_mqtt_battery_soc name: Battery SOC - icon: mdi:battery-{{ (states('sensor.deye_inverter_mqtt_battery_soc') | float(0) / 10) | round(0) | int }}0 + icon: mdi:battery-50 - entity: sensor.deye_inverter_mqtt_battery_power name: Battery Power - secondary_info: "Target: {{ states('sensor.soc_batt_forecast') }}%" + icon: mdi:lightning-bolt + + - type: section + label: EMHASS Forecast + - entity: sensor.p_pv_forecast + name: PV Forecast + icon: mdi:solar-power + - entity: sensor.p_load_forecast + name: Load Forecast + icon: mdi:home-lightning-bolt + - entity: sensor.p_grid_forecast + name: Grid Forecast + icon: mdi:transmission-tower + - entity: sensor.soc_batt_forecast + name: SOC Target (end of day) + icon: mdi:target - # Forecast Comparison - type: section label: Forecast vs Reality - entity: sensor.battery_soc_forecast_error name: SOC Forecast Error - icon: > - {% set err = states('sensor.battery_soc_forecast_error') | float(0) %} - {% if err | abs < 5 %}mdi:check-circle - {% elif err | abs < 10 %}mdi:alert-circle - {% else %}mdi:alert-octagon{% endif %} - - entity: sensor.soc_batt_forecast - name: Target SOC (Forecast) - icon: mdi:target + icon: mdi:chart-bell-curve - # Daily Totals - type: section label: Today - entity: sensor.deye_inverter_mqtt_daily_production @@ -61,27 +64,25 @@ entities: name: Load Consumption icon: mdi:home-lightning-bolt ---- -# Alternative: Compact History Graph +# ─── CARD 2: Battery SOC — Actual vs Forecast (history graph) ──────────────── type: history-graph -title: Battery SOC: Actual vs Forecast +title: Battery SOC — Actual vs Forecast entities: - entity: sensor.deye_inverter_mqtt_battery_soc - name: Actual - color: "#4CAF50" + name: Actual SOC - entity: sensor.soc_batt_forecast - name: Forecast - color: "#FF9800" + name: Forecast Target hours_to_show: 48 refresh_interval: 300 ---- -# Price Timeline Card +# ─── CARD 3: NordPool Prices ────────────────────────────────────────────────── type: entities -title: Price Timeline +title: NordPool Prices +show_header_toggle: false entities: - - type: custom:timeline-card - entities: - - entity: sensor.nordpool_kwh_lv_eur_3_10_021 - name: NordPool Price - title: Spot Price Timeline \ No newline at end of file + - entity: sensor.nordpool_kwh_lv_eur_3_10_021 + name: Current Price + icon: mdi:currency-eur + - entity: sensor.current_hour_price + name: All-in Price (incl. VAT) + icon: mdi:cash