All Projects β†’ markgdev β†’ Home Assistant_octopusagile

markgdev / Home Assistant_octopusagile

Licence: apache-2.0
Octopus Agile custom component for Home Assistant

Programming Languages

python
139335 projects - #7 most used programming language

Projects that are alternatives of or similar to Home Assistant octopusagile

Smarthome
@skalavala πŸ‘ Nothing But Smarthome Stuff! - By Mahasri Kalavala
Stars: ✭ 437 (+1356.67%)
Mutual labels:  home-assistant, home-automation
Homebridge Homeassistant
DEPRECATED in favor of native HomeKit support. - ο£Ώ Homebridge plugin for Home Assistant
Stars: ✭ 666 (+2120%)
Mutual labels:  home-assistant, home-automation
Home Assistant Configuration
🏑 My Home Assistant Configuration Files. Be sure to ⭐️ my repo!
Stars: ✭ 472 (+1473.33%)
Mutual labels:  home-assistant, home-automation
Android
πŸ“± Home Assistant Companion for Android
Stars: ✭ 881 (+2836.67%)
Mutual labels:  home-assistant, home-automation
Amazon Dash
Hack your Amazon Dash to run what you want.
Stars: ✭ 703 (+2243.33%)
Mutual labels:  home-assistant, home-automation
Miflora Mqtt Daemon
Linux service to collect and transfer Xiaomi Mi Flora plant sensor data via MQTT to your smart home system, with cluster support 🌱🌼πŸ₯€πŸ‘🌳
Stars: ✭ 409 (+1263.33%)
Mutual labels:  home-assistant, home-automation
Hassio Zigbee2mqtt
Hass.io add-on for zigbee2mqtt
Stars: ✭ 547 (+1723.33%)
Mutual labels:  home-assistant, home-automation
Zigbee2mqttassistant
GUI for Zigbee2Mqtt running in docker and HASS.IO
Stars: ✭ 371 (+1136.67%)
Mutual labels:  home-assistant, home-automation
Supervisor
🏑 Home Assistant Supervisor
Stars: ✭ 862 (+2773.33%)
Mutual labels:  home-assistant, home-automation
Button Card
❇️ Lovelace button-card for home assistant
Stars: ✭ 680 (+2166.67%)
Mutual labels:  home-assistant, home-automation
Homeassistant
Example Home Assistant Configs
Stars: ✭ 846 (+2720%)
Mutual labels:  home-assistant, home-automation
Room Assistant
Presence tracking and more for automation on the room-level
Stars: ✭ 764 (+2446.67%)
Mutual labels:  home-assistant, home-automation
Homeassistant
Home Assistant Configuration Files and Documentation
Stars: ✭ 395 (+1216.67%)
Mutual labels:  home-assistant, home-automation
Home Assistant Config
Home Assistant config files, rewritten to use the latest features, 100+ documented automations, automatically generated ToC 🏠 πŸ€–
Stars: ✭ 926 (+2986.67%)
Mutual labels:  home-assistant, home-automation
Magic Cards
🎩 Queue music, play movies, or trigger events with RFID cards.
Stars: ✭ 372 (+1140%)
Mutual labels:  home-assistant, home-automation
Esphome Core
🚨 No longer used 🚨 - The C++ framework behind ESPHome
Stars: ✭ 545 (+1716.67%)
Mutual labels:  home-assistant, home-automation
Bruh3 Home Assistant Configuration
(OBSOLETE) BRUH3 Home Assistant Configuration
Stars: ✭ 347 (+1056.67%)
Mutual labels:  home-assistant, home-automation
Haaska
Home Assistant Alexa Skill Adapter that supports v3 of the Alexa Smart Home Skill API
Stars: ✭ 369 (+1130%)
Mutual labels:  home-assistant, home-automation
Ios
πŸ“± Home Assistant for Apple platforms
Stars: ✭ 667 (+2123.33%)
Mutual labels:  home-assistant, home-automation
Dasher
πŸ”˜ A simple way to bridge your Amazon Dash buttons to HTTP services
Stars: ✭ 705 (+2250%)
Mutual labels:  home-assistant, home-automation

home-assistant_OctopusAgile

Octopus Agile custom component for Home Assistant

Referral code

Feel free to use my referral code and get Β£50 credit to your account (as well as mine): https://share.octopus.energy/lilac-bison-793

Installation

Clone this repo and copy custom_components/OctopusAgile to /custom_components/OctopusAgile

Alternatively, install via HACS

Configuration

See the example configuration.yaml config below

region_code

This should match the DNO region code as per the Octopus Agile API - look for "E-1R-AGILE-18-02-21-" on your API dashboard and the next letter is your region code.

mpan, serial, and auth

Your MPAN and serial number are listed on your API dashboard page. "auth" is your API key from the same page.

moneymakers

The concept of moneymakers is devices that should always turn on if the price drops to 0 or below. This can either be a switch or climate device. Note that I have only tested this with my tado thermostat. Populate params as per the example for climate.

Moneymakers are added to the octopusagile.timers entity which is then checked at the beginning of each half hour to decide if the device should be on or off.

timers

Timers are used to turn devices on for a set number of hours each day. I have been using this to turn my immersion heater on for 5 hours a day at the cheapest half hour periods. day_from/day_to can be either "today" or "tomorrow", this is in reference to when the timers are updated (currently hardcoded to 1900Z each day)

Moneymakers are added to the octopusagile.timers entity which is then checked at the beginning of each half hour to decide if the device should be on or off.

The concept of requirements is best explained with an example. My water heater should turn on for 5 hours each day, however it should run for at least and hour between 1900 and 0600 and at least an hour between 1000 and 1600 to ensure that we always have hot water.

Hopefully the other options are self explanatory.

run_devices

This creates a entity detailing the best time period to run a device that needs x number of hours to run. Taking the dishwasher as an example, it runs for 3.5 hours but most energy is used in the first 2.5 so base the run time on 2.5 hours. I want to run the dishwasher before 0800 each night. An entity named octopusagile.dishwasher is created in Home assistant.

sensor

Create a sensor for each of: current rate, previous rate and next rate

octopusagile:
  region_code: "L"
  mpan: 00000000
  serial: 00000000
  auth: abc00000000
  startdate: "2020-05-08"
  moneymakers:
  - switch.water_heater: null
  - climate.downstairs: 
      params:
        temp: 25
  timers:
  - day_from: today
    day_to: tomorrow
    entity_id: switch.water_heater
    numHrs: 5
    params: null
    block: true/false (Optional, not that if requirements are set, the block times will be taken from there.)
    requirements:
      - day_from: today
        day_to: tomorrow
        numHrs: 1
        time_from: '19:00:00'
        time_to: '06:00:00'
      - day_from: tomorrow
        day_to: tomorrow
        numHrs: 1
        time_from: '10:00:00'
        time_to: '16:00:00'
    time_from: '19:00:00'
    time_to: '19:00:00'

  run_devices:
  - energy_time: 2.5
    entity_id: dishwasher
    run_before: '08:00:00'
    run_time: 3.5
  - energy_time: 2.5
    entity_id: washer
    run_before: '08:00:00'
    run_time: 2.5
  - energy_time: 5
    entity_id: wash_dry
    run_before: '08:00:00'
    run_time: 5
  - energy_time: 2.5
    entity_id: dry
    run_before: '08:00:00'
    run_time: 2.5

sensor:
- platform: "octopusagile"

Entities

octopusagile.rates

All future rates stored in entity attributes

octopusagile.avg_rate_exc_peak

The average rate from the day update_timers runs at 23:00 to 22:30 the next day, excluding the 16:00 to 18:30 time periods where the peak rate is applied.

octopusagile.avg_rate_inc_peak

The average rate from the day update_timers runs at 23:00 to 22:30 the next day, including the peak.

octopusagile.timers

All timers as created by the timer configuration listed in entity attribute

octopusagile.region_code

Region code as set in configuration

octopusagile.half_hour_timer_nextupdate

When the half hour timer will next run

octopusagile.half_hour_timer_lastupdate

When the half hour timer last run

octopusagile.update_timers_nextupdate

When the update timers timer will next run

octopusagile.update_timers_lastupdate

When the update timers timer last run

octopusagile.<run_device_name>

A seperate entity for each configured run_device with the time stored in state and start time, start in, end in and average rate stored in the attributes

Example usage

Dashboard

Note that i am using an owl energy monitor for the energy usage stats. I will look at pulling these stats direct from octopus once my agile account is setup Image of Dashboard

Dishwasher

Image of Dashboard

Rates

Image of Dashboard

Rates card

See here Image of Card

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].