- EMHASS config for Deye SUN-12K + 32 kWh battery, NordPool LV - Day-ahead optimization automation (14:30 daily) with real battery SOC init - Forecast vs reality template sensors and dashboard card - Migration log from Domoticz Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
87 lines
2.7 KiB
YAML
87 lines
2.7 KiB
YAML
# EMHASS Dashboard Card
|
|
# Add this to your dashboard (Dashboard → Edit → Add Card → Manual)
|
|
|
|
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 %}
|
|
- 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
|
|
- entity: sensor.deye_inverter_mqtt_battery_power
|
|
name: Battery Power
|
|
secondary_info: "Target: {{ states('sensor.soc_batt_forecast') }}%"
|
|
|
|
# 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
|
|
|
|
# Daily Totals
|
|
- type: section
|
|
label: Today
|
|
- entity: sensor.deye_inverter_mqtt_daily_production
|
|
name: PV Production
|
|
icon: mdi:solar-power
|
|
- entity: sensor.deye_inverter_mqtt_daily_energy_bought
|
|
name: Grid Import
|
|
icon: mdi:transmission-tower-import
|
|
- entity: sensor.deye_inverter_mqtt_daily_energy_sold
|
|
name: Grid Export
|
|
icon: mdi:transmission-tower-export
|
|
- entity: sensor.deye_inverter_mqtt_daily_battery_charge
|
|
name: Battery Charged
|
|
icon: mdi:battery-charging
|
|
- entity: sensor.deye_inverter_mqtt_daily_battery_discharge
|
|
name: Battery Discharged
|
|
icon: mdi:battery-minus
|
|
- entity: sensor.deye_inverter_mqtt_daily_load_consumption
|
|
name: Load Consumption
|
|
icon: mdi:home-lightning-bolt
|
|
|
|
---
|
|
# Alternative: Compact History Graph
|
|
type: history-graph
|
|
title: Battery SOC: Actual vs Forecast
|
|
entities:
|
|
- entity: sensor.deye_inverter_mqtt_battery_soc
|
|
name: Actual
|
|
color: "#4CAF50"
|
|
- entity: sensor.soc_batt_forecast
|
|
name: Forecast
|
|
color: "#FF9800"
|
|
hours_to_show: 48
|
|
refresh_interval: 300
|
|
|
|
---
|
|
# Price Timeline Card
|
|
type: entities
|
|
title: Price Timeline
|
|
entities:
|
|
- type: custom:timeline-card
|
|
entities:
|
|
- entity: sensor.nordpool_kwh_lv_eur_3_10_021
|
|
name: NordPool Price
|
|
title: Spot Price Timeline |