Repository navigation
[FEATURE] Stable full-horizon average for "Discharge only at high price" #569
falberdi
started this conversation in
Feature Ideas
Replies: 1 comment
|
Thanks for the suggestion! 🙌 Here's how this works:
If your idea is very specific to your setup, it may not make it into the core integration — I'll try to suggest a workaround in that case. Feel free to discuss details or alternatives below. |
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Area of the proposal
Energy management or control strategy
What problem would this solve?
With "Descargar solo si precio alto" (discharge only at high price) enabled, I observed that the battery stopped discharging after a restart/manual re-evaluation late in the day. It appears that the price reference is recalculated using only the remaining slots. The exact internal cause has not yet been confirmed.
The improvement I would like is a predictable definition of "high price" across normal evaluation, manual re-evaluation and Home Assistant restarts. Removing elapsed hours from the reference can change the classification of a price even though the published price curve has not changed. This makes the option difficult to understand and can stop household self-consumption during hours that are expensive relative to the full reference period.
Proposed solution
Use a separate, explicitly defined price-reference interval for "Discharge only at high price":
Use a duration-weighted average where intervals have different lengths, including a partial final interval and daylight-saving transitions. If prices are incomplete, expose and document the fallback instead of silently changing the meaning of the average.
This could be offered as a selectable average-reference mode if the remaining-hours approach is an intentional strategy that other users want to retain.
Example use case
Actual PVPC data from my sensor on 2026-10-06:
For a simple above-average comparison, the 22:00 price of 0.34006 EUR/kWh is above the full-day average but below the three-slot average. These calculations illustrate the effect of changing the reference interval; they are not a measurement of the internal threshold used during my observed discharge stop, and additional configured margins or controls may also apply.
Expected result: restarting or pressing Re-evaluate now should not change the price-reference average solely by dropping elapsed hours. When tomorrow's early-morning prices become available and the horizon extends into them, include those slots consistently in the complete reference interval. Allow a change in classification when the underlying prices or defined horizon actually change.
The practical benefit is predictable operation of the high-price discharge setting and clearer explanations for discharge decisions.
Who would benefit from this?
Users with a specific installation or workflow
Alternatives or workarounds
Turning off the high-price discharge restriction would remove the price selection that I want to keep. A fixed absolute price threshold would not adapt to each day's price curve. A separate full-horizon reference, or an explicit choice between full-horizon and remaining-hours averages, would address the underlying requirement.
Additional context
Environment: Omnibattery v1.5.0; Home Assistant Core 2026.9.4; one Marstek Venus E v3; PVPC / ESIOS REE; single-phase installation; no solar panels, with a dummy solar forecast fixed at 0 kWh.
Minimum SOC, protected energy reserves, applicable power limits and other discharge restrictions must still be respected. A full-period average is a more stable reference, but does not by itself guarantee maximum savings or replace an energy-aware optimizer.
This is a development/enhancement request, separate from the bug report about next-day PVPC prices not being included in the planner. Related discussion #270 concerns forced discharge during price spikes; this request concerns consistent average-reference boundaries across re-evaluations and restarts.
Confirmations
All reactions