Replies: 1 comment 1 reply
-
The energy_generated_xxxx sensor is not accurate enough to get decent hourly statistics, the cloud data sampling time is between 3 and 8 minutes, and the Fox cloud api does not reconcile precisely on the hour either - ok for daily, weekly, monthly but not hourly. To get more accurate hourly solar production pass the pv1, 2 power sensors through a riemann sum and then take the resulting energy sensor and create a utility meter that will reset each day - the process is described here https://github.com/macxq/foxess-ha/wiki/Sample-sensors-for-better-solar-monitoring. Note the latest version of home assistant lets you easily create these sensors as helpers (rather than editing your config yaml) - you can do that here Settings, Devices & Services, Helpers - create an integral sensor for PV1 and PV2 (time unit: hourly, integration: left, precision 2 leave other fields blank) and then create utility meters that use these energy source sums and for daily stats(reset daily, always available ). |
Beta Was this translation helpful? Give feedback.
-
Hi
I have this issue, that sometimes a bar is missing under energy dashboard in solar production:

The sensor that is wired in there is: sensor.foxess_energy_generated_cumulative
Afaik we need a sensor like this, that resembles an increasing energy, not actual power. And problem is that there are cases where this sensor is not changed for more than an hour, hence missing the bar. (and yeah there was generation in that time).
So I turned on debug logging and checked when and what data I get. So here are some data that's interesting:
2025-02-18 10:46:09.024 DEBUG (MainThread) [custom_components.foxess.sensor] Var: generation, SN: x set to 16677.0
2025-02-18 10:46:13.323 DEBUG (MainThread) [custom_components.foxess.sensor] OA Daily Generation Report data: cumulative value 16677.0
2025-02-18 10:51:13.184 DEBUG (MainThread) [custom_components.foxess.sensor] Var: generation, SN: x set to 16677.5
2025-02-18 10:56:12.994 DEBUG (MainThread) [custom_components.foxess.sensor] Var: generation, SN: x set to 16677.8
... <fresh value every 5 minutes>
2025-02-18 11:44:58.905 DEBUG (MainThread) [custom_components.foxess.sensor] Var: generation, SN: x set to 16680.3
2025-02-18 11:52:19.984 DEBUG (MainThread) [custom_components.foxess.sensor] Var: generation, SN: x set to 16680.5
2025-02-18 11:52:24.260 DEBUG (MainThread) [custom_components.foxess.sensor] OA Daily Generation Report data: cumulative value 16680.5
Looks like the foxess_energy_generated_cumulative sensor is this part: "Daily Generation Report data: cumulative value". This was updated after 66 minutes (is it scheduled for every hour? not sure), but yeah this can result that there is no change in a whole hour.
The other energy values I extracted is the "Var: generation, SN: x set to ", which is updated every 5 minutes, but I don't see any sensor that relates to this. Am I missing something? The only kWh sensor values I get is those that updated every hour or less often.
How come this is not an issue for anyone else? The data we get from cloud depends on the inverter?
Beta Was this translation helpful? Give feedback.
All reactions