Hi all.
I am new to HA yaml coding and cant understand to solve this. I thought is was easy but after 3 days i give up.
I use the Nordpool dayly energy prices integration where every hours price are updated, sensor.nordpool_kwh_se3_sek_1_10_025. I can se it and it changes every hour so no problem.
I want to control a switch that turn on my boiler every time the price is lower than 100.
I found different examples that i tried but cant get it to work. This is my automation.
Thanks a lot.
Is it that simple?
So now i made my automation as you suggested, whats gonna happend now? So far nothing.
I asume that the trigger only react to a change frome the sensor so i have to wait until sensor.nordpool_kwh_se3_sek_1_10_025 thange the value, is that correct?
I have been doing some C++ som years ago so Yaml is quite different, the indent in yaml is my biggest enemy at the moment.
The sensor must change from above 100 to below 100. You can add more triggers if the sensor is already below 100 when you reload the automaton or if it went below 100 while you were restarting home assistant.
alias: "Boiler on when price low"
description: ""
trigger:
- platform: numeric_state
entity_id: sensor.nordpool_kwh_se3_sek_1_10_025
below: 100
- platform: homeassistant
event: start
- platform: event
event_type: automation_reloaded
condition:
- condition: numeric_state # for the home assistant start and automation reload triggers
entity_id: sensor.nordpool_kwh_se3_sek_1_10_025
below: 100
action:
- service: switch.turn_on
target:
entity_id: switch.switch_boiler
mode: single
I am not shure what i will do whith the integration actually. I have 20.000 sqaremeters land with 5 buildings. A 10.6 kw solar system and a 2kw windmill and a lot of electric things.
Today i have a fixed price for electric. I pay about 1SEK/kw when i buy and i got 2SEK when i sell.
So i am trying to sell as much as i can when i produce from sun and wind and try use as few watts as possible during that time. In the evening when the sun goes down and there is no wind you can say i buy my own electricity for half the price. so its a really good deal for now.
So far it has been sucsessfull today i mainly controll it with some arduinos and i has not get any electric bill for 3 years. Arduino is hard to integrate in HA so now i ongoing switching to ESP32 sensors with integratet Wifi.
So far so good by in May i have to renew my accout at Telgeenergi the Electric company and i suppose they dont give me the same 3 year deal. So i will try to balance the electric consumpion in the moste effective way no matter of the agreement i get from the Electric company. But i asume i got a freerunning price as many other.
Your question abourt how to control with automation, sensor, on/off, price etc. i dont know yet. Lets say boiler can be switched on off easily, but dishwasher, washingmachine and some other equipment can not, they have to run their ful time. So at the moment i making a scedule and priority list so i can do automation from that base.