Closed Topsham closed 1 year ago
When multiplying by the scale, did you use 10 raised to the power of the scale?
Scale being -1, then it would be
Power_ac * (10* scale) Power_ac (10** -1)
Apologies - for clarity I should have included the calculation initially. Consumption = (power_ac x power_ac_scale) - (power x power_scale)
Using the example.py figures this gives the result below of 331.7w compared to the actual consumption at the time example.py was run of 2.65kW so it's not even close. Any thoughts?
>>> result = (15577*(10**-1)) - (1226*(10**0))
>>> print(result)
331.70000000000005
Apologies - for clarity I should have included the calculation initially. Consumption = (power_ac x power_ac_scale) - (power x power_scale)
Using the example.py figures this gives the result below of 331.7w compared to the actual consumption at the time example.py was run of 2.65kW so it's not even close. Any thoughts?
>>> result = (15577*(10**-1)) - (1226*(10**0)) >>> print(result) 331.70000000000005
That's fairly odd. What was the last reported time within the solaredge app?
The script also isn't asynchronous, so it will sequentially get the data, one after the other. The meter data and batteries will be a few seconds behind each other, the consumption amount will vary significantly because of that too. If you run the same script with an interval of a few seconds for about an hour or so, then visualise the data, you may see periodic spikes from "dirty" data
It does indeed seem to be a timing issue. I have fitted my own current clamp to the house consumer unit and compared it to the home consumption figures on the app. They are never the same although they 'trend' correctly over time. As the house consumption is the most dynamic reading, I have decided to use the readings from my own clamp for that and use the modbus readings for solar production and battery % for my smart home needs. So many thanks for your excellent work on this project and I will close this issue.
For my own smart home needs I am trying to extract a home consumption figure from the modbus inverter and meter readouts. It appears this should be (power_ac x power_ac_scale) - (power x power_scale).
At the time the example.py data below was returned, the SolarEdge app was indicating Solar Production of 0.98kW and home consumption of 2.65kW. But using the returned data with the above equation would get nowhere close to the correct consumption figure. Am I missing something?
PS - The battery 'soe's were correct however.