Hello Again,
After spending loads of time reading and re-reading I am still confused.
I prefer yaml - since the gui option is confusing me more as I cannot see what it automatically creates - and recommendation is: you should not mess with .\storage
So after having had something running in the energy dashboard I am back to square one (including ‘you should use new template syntax’)
I have now something showing in the energy dashboard, but I cannot figure out how to put it together using a cost sensor, which is generated from the UI automatically.
This is what I can see right now:
no helpers anymore, although I cant still see some entities when I look at stats/entities
Btw vodoo is some woox device which was supposed to work with tuya local - they never got back to me (wrong decision at purchase - woox or tuya -well learn by spending money :-D)
There is my yaml (ultility meter set up like mentioned in various posts, maybe not that important, but still - what does it)
"#Loads default set of integrations. Do not remove.
default_config:
# Load frontend themes from the themes folder
frontend:
themes: !include_dir_merge_named themes
# Text to speech
tts:
- platform: google_translate
automation: !include automations.yaml
script: !include scripts.yaml
scene: !include scenes.yaml
#DuckDNS setting for certificate
http:
ssl_certificate: /ssl/fullchain.pem
ssl_key: /ssl/privkey.pem
#Customize Yaml for Oil consumption
homeassistant:
customize: !include heating.yaml
sensor:
- platform: energy
name: Oil Consumption Today
state: "{{ states('sensor.oil_consumption_today')}}" # | float(0) * 2.4 }}”
unit_of_measurement: m³
state_class: total_increasing
device_class: gas
- platform: energy
name: Solar Production Today
state: "{{ states('sensor.solar_production_today')}}" # | float(0) * 1.3 }}”
unit_of_measurement: kWh
state_class: total_increasing
device_class: energy
- platform: history_stats
name: Oil Consumption Today
unique_id: oil_consumption_today
entity_id: binary_sensor.vicare_burner_active
state: "on"
type: time
start: "{{ today_at() }}"
end: "{{ now() }}"
- platform: history_stats
name: Solar Production Today
unique_id: solar_production_today
entity_id: binary_sensor.vicare_solar_pump_active
state: "on"
type: time
start: "{{ today_at() }}"
end: "{{ now() }}"
template:
- sensor:
- name: Oelverbrauch
unique_id: oil_consumption_today
state: "{{ states('sensor.oil_consumption_today') | float(0) * 2.4}}"
- sensor:
- name: Solar Warm Wasser
unique_id: solar_production_today
state: "{{ states('sensor.solar_production_today') | float(0) * 9.8}}"
- sensor:
- name: "Energy Solar Production"
unique_id: energy_solar_production
icon: "mdi:flash"
unit_of_measurement: "€/kWh"
state: "{{states('sensor.solar_production_today') | float (0) * 1.5 }}"
utility_meter:
oil_consumption_daily:
source: sensor.oil_consumption_today
cycle: daily
solar_production_daily:
source: sensor.solar_production_today
cycle: daily
oil_consumption_weekly:
source: sensor.oil_consumption_today
cycle: weekly
solar_production_weekly:
source: sensor.solar_production_today
cycle: weekly
oil_consumption_monthly:
source: sensor.oil_consumption_today
cycle: monthly
solar_production_monthly:
source: sensor.solar_production_today
cycle: monthly
oil_consumption_yearly:
source: sensor.oil_consumption_today
cycle: yearly
solar_production_yearly:
source: sensor.solar_production_today
cycle: yearly
And this is my customization.yaml (heating.yaml):
"sensor.oil_consumption_today:
device_class: gas
unit_of_measurement: m³
accuracy_decimals: 2
friendly_name: Oel Heizleistung
state_class: total_increasing
sensor.solar_production_today:
device_class: energy
unit_of_measurement: kWh
accuracy_decimals: 2
friendly_name: Solar Warm Wasser Produktion
state_class: total_increasing
I wanted to follow best practice to split and not have everything in one yaml.
I am getting values in the energy dashboard, but they do not reflect the costs.
Oil burner timer = 2.4 L per hour
Solar production = 9.8kwH = 1 L oil
So what I want to achieve is:
Our daily consumption in oil with costs
and
our daily solar ROI with costs.
Can anyone maybe help to get my confusion sorted?
Since the GUI with helpers and utility meters is not for me, although highly recommended, sorry. I’d like to have it in a yaml file - and long term in yaml files split for customizatiion
Yes, i am a beginner. Still. Although I thought with all the help in this community written down I got quite far. So thank you all (all posts all comments, everyone helping out)
PS:ah, btw these different values within the different sensor creations were meant to help me - but obviously they don’t