This is a simple component to integrate with the Eskom Loadshedding API and provide loadshedding-related status information. Forked from swartjean/ha-eskom-loadshedding
This integration exposes a sensor for the current stage of loadshedding. It also calculates the loadshedding shedule for COCT, and can provide a sensor indicating if the selected Area is currently in loadshedding, as well as when the next loadshedding slot for the selected area will be. this depends of course on the current loadshedding stage.
This component will set up the following platforms.
Platform | Description |
---|---|
sensor |
Show loadshedding status information. |
This component will create the following sensors.
Sensor | Description |
---|---|
sensor.eskom_loadshedding_stage |
Show Current Loadshedding Stage from Eskom API (Numeric). |
sensor.eskom_loadshedding_load_shedding_active |
Is the configured Area currently in loadshedding (True/False). |
sensor.eskom_loadshedding_next_load_shedding |
When the next scheduled loadshedding for the area will take place (DateTime). |
- Using the tool of choice open the directory (folder) for your HA configuration (where you find
configuration.yaml
). - If you do not have a
custom_components
directory (folder) there, you need to create it. - In the
custom_components
directory (folder) create a new folder calledeskom_loadshedding
. - Download all the files from the
custom_components/eskom_loadshedding/
directory (folder) in this repository. - Place the files you downloaded in the new directory (folder) you created.
- Restart Home Assistant
- In the HA UI go to "Configuration" -> "Integrations" click "+" and search for "Eskom Loadshedding Interface"
- Configure the Scan Period (update frequency in seconds). Default is 900s.
- Configure the Area as per COCT map.
NOTE: Long refresh rates kan delay the change of the sensor, as the current implementation does not run on ZERO hour, and refresh times are dependent on startup time. This generally is not an issue in practice. It just seems erratic if you are monitoring the sensor(s).