briancmpbll / home_assistant_custom_envoy

171 stars 76 forks source link

Battery energy discharged and charged data wrong for multiple batteriesÍ #154

Open daraink opened 10 months ago

daraink commented 10 months ago

I am getting a discrepancy with the battery discharge and charge data. compared to my live status view. My Enphase system consisted of four (4) Encharge 10T.

image

image

catsmanac commented 10 months ago

Hi @daraink, the numbers for battery energy charged and discharged are the difference in current battery energy content between 2 data collections. I.e. if current battery changes from 2530 to 2500 Wh the Battery Energy Discharged will show 30 Wh and similar when capacity increases the Battery Energy charged will show the difference. The enphase screen shows the current Power in kW flowing in/out the battery. The power flows results in the capacity change in the batteries.

daraink commented 10 months ago

Thank you for you clarification. How to I get the current Power in KW flowing in/out of the battery? I am trying to use this API to push the data to my chargehq api.

SuperManni72 commented 10 months ago

I am also searching for an solution to get the current power which flows in/out my two 3T batteries OR an additional power consumption entity but without battery charge/discharge power.

catsmanac commented 10 months ago

If you have an encharge the envoy has a page for this which is not currently included in this integration. The updated Home Assistant Core Envoy integration has this and some other battery entities now included it seems, but not sure if it has charged/discharged measurements.

https://envoy/ivp/ensemble/power (you need to authorize with the token to see it.)

    "devices:": [
        {
            "serial_num": "123456789012",
            "real_power_mw": 24000,
            "apparent_power_mva": 24000,
            "soc": 100
        },
        {
            "serial_num": "123456789012",
            "real_power_mw": 16000,
            "apparent_power_mva": 16000,
            "soc": 85
        }
    ]
}
catsmanac commented 10 months ago

OR an additional power consumption entity

@SuperManni72 to measure individual power consumers you best get some device with power clamps or smart power plugs and bring data into HA as ENvoy has no means of doing that. The Envoy metered has only clamps for solar production and grid overall house consumption as far as I know.

catsmanac commented 10 months ago

Getting the additional power data added seems relatively straight forward if people want it. But as said it looks like HA Core may have it now. So adding it may not be needed anymore.