Skip to content
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

Energy dashboard graph error #20712

Open
4 tasks done
john270 opened this issue May 3, 2024 · 3 comments
Open
4 tasks done

Energy dashboard graph error #20712

john270 opened this issue May 3, 2024 · 3 comments

Comments

@john270
Copy link

john270 commented May 3, 2024

Checklist

  • I have updated to the latest available Home Assistant version.
  • I have cleared the cache of my browser.
  • I have tried a different browser to see if it is related to my browser.
  • I have tried reproducing the issue in safe mode to rule out problems with unsupported custom resources.

Describe the issue you are experiencing

For solar installation with battery, and charging from the grid, the 'energy usage' graph is displayed incorrectly. In particular, for the time of charging the battery from the grid the 'grid consumption' bar is incorrectly netted off against the 'battery charge'

Describe the behavior you expected

Night time charging battery from the grid should show two almost equal bars, one positive (for grid consumption) and one negative (for battery charging). Instead what is seen is a large negative (of the correct value), but a only very small positive bar for consumption. By downloading the energy dashboard data, and also separately the values for the related sensors, I can confirm that the 'grid consumption' value used in the graph is 'grid consumption minus battery charge'.
This gives a distorted graph, and also I suspect impacts on the self-sufficiency (and possibly other charts), as in the morning (after battery charging from the grid) self sufficiency is typically around the minus 70%.
'Solar production', 'Sources' and 'TESLA image' all appear to be OK.

Steps to reproduce the issue

  1. Always occurs based on sensor values

  2. Example graph:
    image

  3. Expected graph:
    image

Sensor data and excel graphs attached
history.xlsx

...

What version of Home Assistant Core has the issue?

2024.5.0

What was the last working version of Home Assistant Core?

No response

In which browser are you experiencing the issue with?

Chrome & Android app are consistent

Which operating system are you using to run this browser?

No response

State of relevant entities

No response

Problem-relevant frontend configuration

No response

Javascript errors shown in your browser console/inspector

No response

Additional information

No response

@ChristophCaina
Copy link

Hm... I don't really agree to this expectation.
the Graph should show that x.y kWh went into the charge of the battery.
It does not indicate, from where the energy is comming from.

If you add the same amount of energy to the "taken from the grid" - it would double the total amount of energy used.
MAYBE - another type of bar / color should be used for a battery charged from the grid?

Something like this?
grafik

@john270
Copy link
Author

john270 commented May 7, 2024

@ChristophCaina , to clarify, the issue is not the 'battery charge' bar, it is the 'from grid' bar. Currently the graph shows the battery charge as negative usage (which I agree with) but shows only very marginal grid usage, giving a net usage of very negative electricity - which is the issue, as actually it should be close to zero usage (slightly positive). Negative overall usage would be expected like that if the battery was charging from solar but it is not. Not sure extra bar colours are the answer - it would still show negative usage, and already grid and battery are different bars.
I do agree though that adding an extra amount of source energy to the graph will (does - as I've tested it) corrupt the overall usage totals

@ChristophCaina
Copy link

I think, showing the Battery charge from the grid in another color is the only way - just like there's a difference in solar - when exported to the grid or charged into battery.

The main thing here is, that you consume energy from the grid to charge the battery.
The same applies for chariging the battery from solar.
It SHOULD show the amount to charge the battery as "positive" usage - in theory...

But this also applies for using energy from the battery.
With the current logic, I only see the different color as a possible solution

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants