HA loadshedding automation

Andrew001

Well-Known Member
Joined
Aug 23, 2018
Messages
193
Reaction score
49
Looking for some advice with people familiar with loadshedding hacs add on, eskomsepush api and then setting up a automation.


Been struggling a bit trying to get it going.

Any help would be greatly helpful.

edit: Ive got the eskom api intergrated, as well as solar assistant and the loadshedding addon from the hacs running. The main issue is setting up the inverter to change to grid 2 hours before loadshedding, when solar panels watts drop below 200 and battery volts drop below 11.5 lets say
 
Last edited:
yes thanks i have the add on already installed.
im looking for help with an automation with it.
 
yes thanks i have the add on already installed.
im looking for help with an automation with it.
What are you trying to do exactly?

I'm still a HA noob, but got a few things running yesterday.

This turns my geyser off 10 minutes before loadshedding starts (if in the evening) and notifies me on my phone:

Code:
alias: Disable Geyser during evening loadshedding
description: Turns off the geyser when there is loadshedding scheduled during the evening.
trigger:
  - platform: numeric_state
    entity_id: sensor.load_shedding_area_westerncape_14_tableview
    attribute: starts_in
    below: 10
condition:
  - condition: and
    conditions:
      - condition: numeric_state
        entity_id: sensor.load_shedding_stage_eskom
        attribute: stage
        above: 0
      - condition: sun
        before: sunrise
        after: sunset
        before_offset: "01:00:00"
        after_offset: "-01:00:00"
action:
  - type: turn_off
    device_id: 8191db6e8c154b44165d3b6482a0e759
    entity_id: switch.geyser_switch_switch_1
    domain: switch
  - service: notify.mobile_app_iphone_144
    data:
      message: The geyser switch has been turned off due to upcoming loadshedding.
      title: Geyser Disabled
mode: single
 
Thats not too bad for a noob.
I could try edit your code a bit as i think it contains some of things i was struggling with.

However what im after is in essence changing the priority of my inverter to grid, say 2 hours before load shedding, when PV is below 200w and battery voltage is say 11v.

I have a small setup - 1kva voltronic, 12v lifepo4, with a simple daly BMS (not connected to inverter)
 
Thats not too bad for a noob.
I could try edit your code a bit as i think it contains some of things i was struggling with.

However what im after is in essence changing the priority of my inverter to grid, say 2 hours before load shedding, when PV is below 200w and battery voltage is say 11v.

I have a small setup - 1kva voltronic, 12v lifepo4, with a simple daly BMS (not connected to inverter)

Also a noob but I have managed to use HA and the ESP API to hibernate PC's, and switch various lights and Aircon off before LS hits.

My automations fire based on the predicted time of a LS state as per the ESP API.

I'm assuming that HA picked up your inverter, has created the relevant entities and is able to control the the inverter state via those entities?
 
Also a noob but I have managed to use HA and the ESP API to hibernate PC's, and switch various lights and Aircon off before LS hits.

My automations fire based on the predicted time of a LS state as per the ESP API.

I'm assuming that HA picked up your inverter, has created the relevant entities and is able to control the the inverter state via those entities?
Yes it's picked up the inverter etc via solar-assistant.
Im mainly struggling with the automation side and am horrific at the yaml coding.
 
I've found a few nice pieces of code since my. Original post and was thinking of tinkering with it as you mentioned.
We do have a 5 month old so my time has evaporated lol.
I was thinking even paying for these services or for a lesson or two.
One thing I remember struggling with was the action part of the automation which the inverter entity didn't really give options.
 
I've found a few nice pieces of code since my. Original post and was thinking of tinkering with it as you mentioned.
We do have a 5 month old so my time has evaporated lol.
I was thinking even paying for these services or for a lesson or two.
One thing I remember struggling with was the action part of the automation which the inverter entity didn't really give options.
Does the SA integration to your inverter allow you to change inverter states? I know for Sunsynk/Deye this only arrived as a feature late last year
 
I've got one of those sonoff load shedding notifiers and use simple HA automations to turn things off and announce to the house via speaker. Works a charm.

Also use eskomsepush via api and token to give warnings etc using automations. I can't code anything.


941946b11d1b1f2016f1aec9771cbdfd.jpg
 
Does the SA integration to your inverter allow you to change inverter states? I know for Sunsynk/Deye this only arrived as a feature late last year
It's currently down in HA I think from putting Solar Assistant onto the wifi signal booster / externder thing and HA being on the original router, however from what i remember seeing last week was that it was editable.
It seemed to work with the trigger and condition but not with the action.
Will try to get it up and running tomorrow to confirm
 
Last edited:
I've got one of those sonoff load shedding notifiers and use simple HA automations to turn things off and announce to the house via speaker. Works a charm.

Also use eskomsepush via api and token to give warnings etc using automations. I can't code anything.


941946b11d1b1f2016f1aec9771cbdfd.jpg

What's the 'sonoff loadshedding notifier'?
 
What's the 'sonoff loadshedding notifier'?


I hooked mine up to my change over switch. Comes up as a switch on ewelink but you don't ever change it. It's changes with sensening what has power - Inverter or mains.

Only issue I can't work out is how to turn on stuff after loadshedding stops with a delayed time.

Eg. Loadshedding stops. Inverter charges for 3 hours. Then geyser turns on
 
Does the SA integration to your inverter allow you to change inverter states? I know for Sunsynk/Deye this only arrived as a feature late last year
It seems it allows one to change things within SA, but so far I cannot find anything within HA.
What I found is this: See pic 1- which looks like sensors only.
Pic 2: showing no available
 

Attachments

  • pic1.jpg
    pic1.jpg
    97.7 KB · Views: 26
  • pic2.jpg
    pic2.jpg
    79.8 KB · Views: 28
Only issue I can't work out is how to turn on stuff after loadshedding stops with a delayed time.

Eg. Loadshedding stops. Inverter charges for 3 hours. Then geyser turns on
You can create a scene in Ewelink which has the ability to add a delay. So one scene that will turn on whatever you want. Or multiple scenes with varying degrees of delay.
 


I hooked mine up to my change over switch. Comes up as a switch on ewelink but you don't ever change it. It's changes with sensening what has power - Inverter or mains.

Only issue I can't work out is how to turn on stuff after loadshedding stops with a delayed time.

Eg. Loadshedding stops. Inverter charges for 3 hours. Then geyser turns on

Hmm, if you have HA up and running and a way of detecting whether the grid is up or down (by reading the state of a device on your non-essentials side, would you still need this device?
 
Top
Sign up to the MyBroadband newsletter
X