home-assistant / core

:house_with_garden: Open source home automation that puts local control and privacy first.
https://www.home-assistant.io
Apache License 2.0
71.14k stars 29.81k forks source link

Enphase - inverters not reporting #124493

Closed abwino closed 1 week ago

abwino commented 2 weeks ago

The problem

This morning I noticed that the Enphase integration was asking to be re-configured. I obliged with my Enphase user details and everything looked fine. Later I noticed that the inverters were all reporting around 145w each although it was bright and sunny. Looking at the inverter logs, I saw they all flatlined when it got dark and then, just before midnight they all spiked up to 50w and haven't moved since. I power cycled all the Enphase kit a couple of times but no change. I'm assuming Enphase updated the cloud interface last night? The 'current power production' entity is reporting correctly.

What version of Home Assistant Core has the issue?

2024.8.2

What was the last working version of Home Assistant Core?

No response

What type of installation are you running?

Home Assistant OS

Integration causing the issue

Enphase

Link to integration documentation on our website

https://www.home-assistant.io/integrations/enphase_envoy

Diagnostics information

No response

Example YAML snippet

No response

Anything in the logs that might be useful for us?

No response

Additional information

Screenshot 2024-08-23 at 15 54 54
home-assistant[bot] commented 2 weeks ago

Hey there @bdraco, @cgarwood, @joostlek, @catsmanac, mind taking a look at this issue as it has been labeled with an integration (enphase_envoy) you are listed as a code owner for? Thanks!

Code owner commands Code owners of `enphase_envoy` can trigger bot actions by commenting: - `@home-assistant close` Closes the issue. - `@home-assistant rename Awesome new title` Renames the issue. - `@home-assistant reopen` Reopen the issue. - `@home-assistant unassign enphase_envoy` Removes the current integration label and assignees on the issue, add the integration domain after the command. - `@home-assistant add-label needs-more-information` Add a label (needs-more-information, problem in dependency, problem in custom component) to the issue. - `@home-assistant remove-label needs-more-information` Remove a label (needs-more-information, problem in dependency, problem in custom component) on the issue.

(message by CodeOwnersMention)


enphase_envoy documentation enphase_envoy source (message by IssueLinks)

catsmanac commented 2 weeks ago

Hi @abwino, it might be that Enphase pushed a firmware version to your Envoy and triggered this. They are in the process of pushing firmware out in various parts of the world as result of reported vulnerabilities. The new firmware is 8.2.42xx.

Is there anything visible in the home_assistant.log file?

Can you upload the HA Enphase Envoy diagnostic file here?

afbeelding

abwino commented 2 weeks ago

Hi, thanks for the quick reply! There is nothing in the HA log file.

I have the Envoy-S-Metered-EU. The app reports the current firmware as D7.0.88

Diags attached. Good luck sir! :)

config_entry-enphase_envoy-7f64ceffc3b3831b7711f8ab6cf85c52-2.json

catsmanac commented 2 weeks ago

So no firmware push triggering this.

There's nothing that stands-out as error in the diagnostics file. When inspecting the inverter data, the last reported time spans from 19:43 to 20:02. That can be ok if that is around sunset when they stopped producing.

Is the Envoy connected over ethernet cable of Wifi?

production report time: 2024-08-23 21:47:20

inverter     last reported         Watts    MaxWatts
121521044774 2024-08-23 19:58:13    0          167
121521037473 2024-08-23 20:01:27    0          168
121521047154 2024-08-23 20:02:03    0          172
121521047070 2024-08-23 20:01:32    0          172
121521046971 2024-08-23 20:01:33    0          170
121521037506 2024-08-23 20:01:36    0          166
121521041060 2024-08-23 20:01:06    0          173
121449041330 2024-08-23 20:02:16    0          169
121521036595 2024-08-23 20:01:13    0          173
121521047386 2024-08-23 19:59:38    0          170
121521047138 2024-08-23 20:01:44    0          172
121521044111 2024-08-23 20:01:46    0          169
121521044651 2024-08-23 20:01:18    0          172
121521044355 2024-08-23 20:01:49    0          172
121521040308 2024-08-23 19:43:32    0          171
121521047163 2024-08-23 20:01:55    0          175

On to the next step then. Can you enable debug and let it run so it catures some solar production as well as overnight.

Enable debug, let it run and then disable it again. When disabling the log file will download to your pc. Best zip it and then upload here so I can inspect what the inverters are reporting over time.

afbeelding

abwino commented 2 weeks ago

Hi Arie, sorry for the delay. T [Uploading home-assistant_enphase_envoy_2024-08-29T18-17-08.930Z.log.zip…]() he Envoy is connected via ethernet cable. I was beginning to think I'd made the whole thing up as the readings seemed to move back to normal. But then today I got a perfect example for you, we had a bright sunny day where the Current Power Production value bore little relation to what the inverters were reporting. The CPP always looked correct but the inverters were reporting far less wattage than I would expect. I hope this log demonstrates what I'm seeing.

catsmanac commented 2 weeks ago

Thanks Andrew. I think you closed the comment before the upload was finished. The link still shows uploading and ... in the name and when I click it it just takes me to this topic again instead of downloading the zip file. Can you upload the file again and wait with closing the comment until the upload finished.

abwino commented 2 weeks ago

home-assistant_enphase_envoy_2024-08-29T18-17-08.930Z.log.zip

abwino commented 2 weeks ago

Hi Arie, I think that has uploaded now. Thanks :)

catsmanac commented 1 week ago

That worked Andrew.

I think what we are seeing is the lag in inverter data because of a 15 minute update cycle. In the middle section of the graph below you can see it clearly when production is ending for the day, the CT reports already 0 while the 15 min reports of the inverters are coming in slowly and takes more time for all of them to report 0.

Typically the Envoy will request updates from the inverters every 5 minutes. I think it will switch to 15 min if communication bandwidth is low or connection is poor.

Ran the debug log file through my little debug dissector to get all raw data from it: debug_report.txt.

The file contains various tables in csv format with a legend below if you want to inspect the data yourself. There's 3 debug periods in the file, 2024-08-27 11:59:42 - 2024-08-27 13:01:02, 2024-08-27 18:28:48 - 2024-08-27 20:29:04 and 2024-08-29 14:47:56 - 2024-08-29 19:16:10.

When comparing data of the production power of the Current Transformer (CT) and the sum of individual inverters power we see below trend, the 2 vertical red lines separating the 3 periods in the data:

afbeelding

Looking at the data for the inverters in last section of the file (might still be called power report in the uploaded file):

The issue will be least noticeable under stable or slow changing solar conditions. The right hand data for August 28 shows the case with more varying solar conditions. The current transformers report changing conditions expressed in changed power output while the inverters again catch up more slowly.

An clear example here is where the CT power drops suddenly at samples 247-262, at 262 the inverters are all down as well. (Between every sample is ~60 seconds, see column interval in report last section)

In a plot of 4 of the inverters power, the 15 min cycle and varying update moments is clearly visible as well:

afbeelding

There's no log of a night, can't say much about the nightly inverter peak mentioned in the original report.

catsmanac commented 1 week ago

According to the manual the inverter data should update every 5 minutes. But we've seen it being changed to once per hour as well. Enphase support can apparently set it back to the 5 minutes. See this topic for some experiences with this. (It's a topic in custom integration, but the issue applies to the envoy itself, not to the integration)

dshefman commented 1 week ago

I think I'm seeing a similar effect. The Envoy sensors keeps flipping to "Unavailable" every few minutes. This started happening when I updated the home assistant firmware.

image

Actually if it helps, the debug log says: ERROR (MainThread) [homeassistant.components.enphase_envoy.coordinator] Error fetching Envoy 121950047565 data: Error communicating with API: HTTPX Timeout

catsmanac commented 1 week ago

Hi @dshefman, your issue is differrent from what @abwino reported. There's no timeout's and unavailable status in Andrew's log. The issue with Andrew's Envoy is that the Envoy only refreshes the inverter data every 15 minutes, but all communication to Home Assistant works fine.

In your case it's the Envoy not responding to data requests from Home Assistant. Can you open a new issue for your problem and include a debug log file that has a couple of occurrences of the time-outs.

abwino commented 1 week ago

Hi Arie. Sorry for the late reply. Thank you so much for taking such an in-depth look at my data, I really do appreciate. I really happy that everything is working as expected, I'm sorry if I have wasted your time. Kindest regards,

Andrew.

catsmanac commented 1 week ago

Hi Andrew, no waste of time at all, with each question I learn a bit as well. Glad I could help.

As said, your installer or Enphase support might be able to change the interval from 15 to 5 minutes. This manual on their documentation site mentions the 5 minute interval.

catsmanac commented 1 week ago

@home-assistant close