-
Notifications
You must be signed in to change notification settings - Fork 19
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Battery data not in database #55
Comments
Incomplete. I am not even sure if the data collected is correct as I have no battery to test with. |
I have a battery. I could test if you'd like. I have everything compiling
now, so it should be fairly simple to run, test, collect data.
If you tell me what you need, I can carve out time to do it.
…On Sat, Apr 22, 2023, 16:05 dlmcpaul ***@***.***> wrote:
Incomplete. I am not even sure if the data collected is correct as I have
no battery to test with.
—
Reply to this email directly, view it on GitHub
<#55 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AD2PAI5U3YSH3A5OKU3STZDXCRP3RANCNFSM6AAAAAAXH4E3BQ>
.
You are receiving this because you authored the thread.Message ID:
***@***.***>
|
Ok I committed some code to dump the battery info to logs. Please run and let me know what sort of data we are getting so we can decide what to write to the database. Be good to see data for
|
Where are the logs? Console logs aren't showing battery info.
|
You look to be running release 0.26 instead of from the current code base. How are you starting the application? |
Oh I was running the
Still no battery logs though.
|
I made the code changes to this file https://github.com/dlmcpaul/EnphaseCollector/blob/master/src/main/java/com/hz/utils/MetricCalculatorStandard.java and just log out what is in the 2 battery lists. My first thought is that neither array is being populated. Are your batteries Enphase or another brand? |
Enphase batteries.
Is there a curl command I can send to my gateway to get a list of
batteries. I've been looking for some REST API docs for it, but no luck so
far.
I also haven't found the api endpoints in your code.
…On Sun, Apr 23, 2023, 08:13 dlmcpaul ***@***.***> wrote:
I made the code changes to this file
https://github.com/dlmcpaul/EnphaseCollector/blob/master/src/main/java/com/hz/utils/MetricCalculatorStandard.java
and just log out what is in the 2 battery lists.
My first thought is that neither array is being populated.
Are your batteries Enphase or another brand?
—
Reply to this email directly, view it on GitHub
<#55 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AD2PAI4J373U3GEM5U7RBEDXCVBIFANCNFSM6AAAAAAXH4E3BQ>
.
You are receiving this because you authored the thread.Message ID:
***@***.***>
|
The
|
I may have found something, but I have family obligations so I can't continue to investigate. from this: https://enphase.com/download/accessing-iq-gateway-local-apis-or-local-ui-token-based-authentication
|
Oh, I have 2 batteries btw |
A little bit more digging, and I found |
Under |
I found this, which might be helpful. Given how much work you've already done, you may have already known about it. |
Hmm, I read the envoy expecting either a list of storage devices (type acb) or an entry in the inverters (devtype 11). This page gives a little info on the production endpoint and it thinks storage devices should show up https://github.com/Matthew1471/Enphase-API/blob/main/Documentation/IQ%20Gateway%20API/General/Production.adoc Can you get the raw data from /production.json?details=1 |
Here is the output. Note, it's currently dark out and my batteries are set to full backup and are fully charged, and are not supplying any power to the house. Also, some other facts about my house I can get you the output again tomorrow, with the batteries charging/discharging etc. /production.json?details=1
|
Looks likes the batteries are not wired into the enphase controller. Is that something you can ask your installer about?
Also no percentFull value which I was expecting. |
Interesting. Seems like they have a bug...
However,
The enphase app clearly shows my battery status, so it's physically hooked up and working. Seems like these APIs aren't returning the correct data through. I'll open a support ticket with enphase to see what's up. |
Yes, the perils of trying to reverse engineer the data :-) If the app is showing the battery data then it should be in there somewhere but will enphase tell us. using the 86000 = ?KWh |
I've asked enphase to see if I can get more documentation on the APIs...
we'll see.
I have the enphase IQ10 batteries. 2 of them, which should hold 20kWh
https://enphase.com/download/iq-battery-10-data-sheet
They are currently fully charged and /ivp/livedata/status return
"storage": {
"agg_p_mw": -99000,
"agg_s_mva": -99000,
"agg_p_ph_a_mw": -99000,
"agg_p_ph_b_mw": 0,
"agg_p_ph_c_mw": 0,
"agg_s_ph_a_mva": -99000,
"agg_s_ph_b_mva": 0,
"agg_s_ph_c_mva": 0
},
No idea what -99000 means though :(
…-Steffen
On Mon, Apr 24, 2023 at 3:21 PM dlmcpaul ***@***.***> wrote:
Yes, the perils of trying to reverse engineer the data :-)
If the app is showing the battery data then it should be in there
somewhere but will enphase tell us.
using the /ivp/livedata/status does agg_p_mw match anything you know
about your batteries?
86000 = ?KWh
—
Reply to this email directly, view it on GitHub
<#55 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AD2PAIYP72Y56QQ2OVXKLDLXC34GTANCNFSM6AAAAAAXH4E3BQ>
.
You are receiving this because you authored the thread.Message ID:
***@***.***>
|
mw suggests watts Batteries are usually rated with kWh and kVA so that might line up. But honestly my first thought was some sort of percentage figure. Fully charged could be 99% and the previous reading you sent could be 86% Maybe just record the values and compare to what the app shows. |
Recording the value would be a great idea! If you treat it like other metrics and just write it to a debug table in the database, then we could graph it and compare to the app graphs. |
Hmm, it looks like Before we get too far, maybe just manually record some values. |
It would have been too simple if the current cloud api version had the same
API as the v1 local API.
I was hoping that, just maybe, one of the current APIs returned a similar
JSON so we could compare, but I didn't see anything.
But we could use the current cloud API to record the battery state, and
then compare that to what we're seeing, but it is a lot of extra effort.
If we just record the current value, then I'll get it up and running and
I'll do a side by side graph comparison of the graphs to see if I can find
a pattern.
…On Mon, Apr 24, 2023, 20:16 dlmcpaul ***@***.***> wrote:
Hmm, it looks like /ivp/livedata/status does not exist for the V5 enphase
release.
Before we get too far, maybe just manually record some values.
—
Reply to this email directly, view it on GitHub
<#55 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AD2PAI564XX4B62HV42GJX3XC46XBANCNFSM6AAAAAAXH4E3BQ>
.
You are receiving this because you authored the thread.Message ID:
***@***.***>
|
After asking enphase very nicely over and over again, I finally got some documentation on the REST API Endpoints :) I think the following endpoint may get us battery power, but I haven't had a chance to try it yet. |
Ok, when you do let me know the response you get and I can see about creating a model. |
Hello. I just wanted to add that from my learning of the API there is a difference between:
.. ACB couldn't be deployed outside, talked directly to the Gateway via PowerLine Communications (PLC) just like the microinverters and .. .. The The
This page is helpful to work out the terms : https://support.enphase.com/s/article/What-are-the-new-names-for-Enphase-products-And-why The meters may also have sight of "battery data" from the CT clamps. I don't have Enphase battery storage as they do not appear to offer it in my country (United Kingdom). However my Telsa PowerWalls are being fitted this week. I'm happy to update my API documentation with other people's API response data however. The document from #55 (comment) looks like it's straight out of the Enphase Confluence, which is kind of fascinating considering their documentation seems more patchy than mine. I'm still trying to find out what "IVP" (in the URLs) stands for as part of my goal with the API documentation was to expand any terms referenced. |
Well I now have Enphase IQ Battery 5P added to my system so I have been poking about a bit. I can see the total battery availability and the current state of charge but have yet to find the usage values. Will look more at the /ivp/livedata/status endpoint. |
The codebase has code to get the battery info, for instance: https://github.com/dlmcpaul/EnphaseCollector/blob/master/src/main/java/com/hz/models/envoy/json/Production.java#L42
However, none of it shows up in the database.
Is this an incomplete feature or a bug?
The text was updated successfully, but these errors were encountered: