@del13r Out of interest, have you tried @vk2him ’s new mqtt add on? I’ve been chatting to him on the repo because I’ve been having some trouble getting it to work reliably. For me, sometimes it kicks in immediately, sometimes it doesn’t, sometimes it kicks in after several minutes etc. Just looking for another data point…
I finally got around to doing this.
The only issue I had was that I started doing it on mobile and the configuration tab was not initially obvious to me. On mobile it just shows some gears at the bottom of the page where as on desktop/laptop it actually says the word configuration on the top of the page.
Once I got past that, i was able to configure the addon with the same details I had in the original script I used to run and it now works perfectly.
One thought I had as I was configuring this addon was that in the past I used to use hostnames instead of IP addresses and I would experience issues if I rebooted my router.
I then started reading how home assistant under certain conditions might use cloudfare dns rather than the dns on your lan. see Local DNS! - #109 by CentralCommand
I then replaced my hostnames like envoy.local with the actual IP address in an attempt to give it more resiliency.
@del13r Thanks for getting back. The problem I had with long delays before the add-on kicked in seems to have been solved by a Core reboot. I’m very happy with having this run inside HA - one less thing to worry about. Thanks @vk2him! It will be interesting to see how the V7 firmware issue plays out in the long run.
It looks like it may be safer staying with V5 for the time being.
I have seen posts suggesting contacting Enphase with downgrade request or preventing the upgrade to V7 for particular system.
Have anyone successfully tried that (contacting Enphase)?
Is the upgrade path known? Can I perhaps filter some ports / URL on my router to prevent upgrade while still keeping the cloud connectivity (until I may be able to cut the cord one day)?
Yes I contacted Enphase support by phone - after discussion the helpful lady I spoke to said they could downgrade me from V7 to V5 and keep me permanently on V% till I called and asked to be upgraded. I needed v5 so my mqtt script worked. I’ve now made my script an add-on to Home Assistant to give readings once per second for realtime display
Thanks! I Just did the same. Very helpful lady (on a noisy call center line). Few minutes on hold while she talked to a senior tech support person and then confirmed I will not be upgraded unless I request to.
Time to invest into more automation! Thanks a lot for your contribution.
This thread is amazing, and started getting me through my configuration of the Energy settings. But I have to ask… has this been started up on a new thread that’s more consolidated in the “best practice” configuration at this stage? There are so many different perspectives, fixes, etc–its a bit overwhelming to go through and absorb.
Good point. I might do a re-write and break it down into so its easier to understand. I was rushing to fit so much into a single post. The original post 1 still works if you fully follow the instructions.
We are all using the same Envoy API {URL}/stream/meter
I am wondering if anyone succeeded in understanding of the dependencies of the individual values in each JSON record.
To be specific: I have Envoy on a common US split phase (120V + 120V 180°) system.
The production consists of set of 240V inverters connected between the two phases with one current sensor (CT).
On the consumption side there are two phases (A and B) with respective CTs.
All that Envoy is able to measure are three (3) currents and two (2) voltages and phase differences between the currents and voltages expressed as Power Factor.
Yet the API spews many more values. This may be fine - if the arithmetic between the different values would match, right? Voltages: The Envoy can measure only pair of voltages (on the split phase system) (ph-a and ph-b) but reports three pairs - one each for “production” “net-consumption” and “total-consumption” that are each slightly DIFFERENT. Playing with the numbers in Excel it looks like “total-consumption” voltages are averages of the “production” and “net-consumption”. All I can think of is that the ADC is multiplexed and the readings are taken at different moments. Apparent power (s) is mostly matching product of Voltage * Current (as it should) though the errors are more than what would look like a rounding error but stay mostly well below 1W though I have noticed random excursions much higher than that.
For Power (p) and Reactive power (q) the "total-consumption"="production"+"net-consumption". At least something else I can agree with.
In case of the Apparent Power (s) the “net-consumption” sign needs to be flipped depending on the direction of the total flow (from or to utility).
But the power factor values reported by Envoy are far from matching the expected PF=p/s formula.
On top of that - how could there be two different power factors related to a single phase generation?
Can anyone explain the dependencies so I can sleep again?
I want to throw away redundant properties and calculate what I want from the fundamental measured values.
@mvana - I’ve written a python script that uses the /stream/meter and converts it to a mqtt feed for Home Assistant - I use all three phases and the script can isolate all values needed. Check it out here: