Comments (3)
Interesting! You should be able to work around this by using an automation to update an input_number
integration when the Octopus integration entity changes rather than using the value of it directly. This should avoid the entity becoming unavailable if it depends on cloud sources such as the Octopus one and also allows it to be updated by other sources too if you have e.g. incoming solar energy.
In my case, I use Octopus Intelligent and I have a similar automation because that integration doesn't tell me the price, only if it's currently on the "low" or "high" prices, so I use that to update my input_number
appropriately.
I don't think it would necessarily always be a good idea to ignore "unavailable" states as this could result in silent inaccurate measurements, which as you say may not be the correct fix for every use case, so for you and anyone else with similar issues, I would recommend doing this.
from teslamateagile.
Thanks @MattJeanes what you suggested is actually a very good idea, I created a simple automation
alias: Copy Octopus Tracker Electricity Rate to Teslamate
description: ""
trigger:
- platform: state
entity_id:
- sensor.octopus_energy_electricity_xxxxxxxxxxx_xxxxxxxxxxxxx_current_rate
condition:
- condition: not
conditions:
- condition: state
entity_id: >-
sensor.octopus_energy_electricity_xxxxxxxxxxx_xxxxxxxxxxxxx_current_rate
state: unavailable
- condition: state
entity_id: >-
sensor.octopus_energy_electricity_xxxxxxxxxxx_xxxxxxxxxxxxx_current_rate
state: unknown
action:
- service: input_number.set_value
metadata: {}
data:
value: >-
{{
states('sensor.octopus_energy_electricity_xxxxxxxxxxx_xxxxxxxxxxxxx_current_rate')
| float }}
target:
entity_id: input_number.teslamateoctopustracker
mode: single
This should copy the electricity rate from the Octopus add-on to a numeric input "input_number.teslamateoctopustracker" when the status is not "unknown" or "unavailable", I'm sure it can be massively improved (I'm not great with templating) but it seems to do the job.
from teslamateagile.
That looks perfect to me, nice!
Hopefully that does the job for you, so I'll go ahead and close this :)
from teslamateagile.
Related Issues (20)
- Multiple providers? HOT 2
- Feature request? Generic input of dynamic pricing HOT 2
- Calculation fails when the end time of a charge is very close to the beginning of the hour HOT 3
- Unable to calculate cost of some charges HOT 11
- Create REST endpoint to get price at specific datetime HOT 3
- Failed to update prices - System.ArgumentException: totalHours HOT 6
- Failed to calculate charging cost / energy for charging process HOT 6
- Enhancement / Feature Upgrade - integration of EMS evcc HOT 2
- Unable to download docker image HOT 2
- Feature request - Make available in Home Assitant hassio HOT 15
- Feature request: Day of week in FIxedPricing
- Tibber "Failed to calculate charging cost" HOT 8
- Feature Request: Fixed Pricing Based on Day of Week HOT 2
- TeslaMateAgile.PriceHelper Tibber fails HOT 6
- No data available if multiple homes exist HOT 10
- Feature request : Show the energy prices in a dashboard HOT 5
- Feature request: monitoring multiple geofence IDs HOT 3
- Help needed: "number-based entity" in HomeAssistant clarification HOT 4
- TeslaMateAgile.PriceHelper Tibber fail HOT 5
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from teslamateagile.