-
-
Notifications
You must be signed in to change notification settings - Fork 785
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add support for Amber Electric (AU) #12381
Conversation
@ross-w the update is not a problem. I'm afraid though that evcc would continue charging for the current period (i.e. 1hr) even if the current slow- due to price increase- would no longer be part of the plan. We've added this to prevent switching off to frequently. /cc @schenlap maybe we'll need another parameter to account for potentially frequently-changing price conditions? @ross-w does this require and api key? Would be great to share with [email protected] as I cannot support this otherwise. |
Would you also add a template for the Tariff? See https://github.com/evcc-io/evcc/tree/master/templates/definition/tariff for examples. We'll use these in the near future. |
Thanks for the info @andig will definitely keep that in mind. For now I can work around the problem by having Home Assistant detect price spikes and set the loadpoints to off via the API. It would be nice to have a native solution for this in evcc longer term. API key is required. Understand the requirement for support, that said the API key is personal to me and my property and you can do more than just read prices with it. I'll email to discuss. I've added a template as requested. Hope it looks OK; I'm not sure how to test it. |
Great PR, thank you! |
Please confirm that I understood correctly: |
I'm fairly new to Golang so I'd appreciate any comments on how this code might be improved.
This adds support for Amber Electric (Australia) as a variable tarriff, for both grid imports and exports (feed-in.)
API documentation is available at https://app.amber.com.au/developers/ though unfortunately you need an account to obtain an API token.
The API returns both import and export pricing in the one call, so the result needs to be filtered by "channel", which can be
general
,feedIn
, or another one for controlled loads (I don't have any, so I can't confirm what this looks like)One striking difference to other variable tarriffs in evcc is that I have this updating every minute. Most people using the Amber API tend to use this interval (the official Home Assistant integration also polls every minute). The prices tend to fluctuate and can make sudden movements, so it's fairly important to keep this up to date. If 1 minute is not acceptable, 5 minutes is likely OK, but hourly would be too infrequent. As an example we had a swing from around $0.10 to around $19.00 (yes, really) last week due to a sudden fault causing spot prices to skyrocket. I'd have not wanted my charging to continue at full power for another hour until the next refresh, as this would have cost a bomb!
Screenshots attached of a local build, compared to what Amber's site is showing me presently:
