Skip to content
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

Support new Battery mode "Weather forecast" #11

Open
thomasfoxl opened this issue Sep 8, 2020 · 20 comments
Open

Support new Battery mode "Weather forecast" #11

thomasfoxl opened this issue Sep 8, 2020 · 20 comments

Comments

@thomasfoxl
Copy link

Due to the additional battery setting "weather forecast" calling self.set_batt_settings({"alg_setting": "on"}) doesn't work anymore.

@gluap
Copy link
Owner

gluap commented Sep 8, 2020

@thomasfoxl unfortunately I didn't get that update yet (I've been hoping for this feature for some time now). As soon as I get it I can look into reverse-engineering it.

For reference:
My ESS is currently at:

PMS SW Version: 10.05.6511/08.04.2020 R1603
PCS SW Version: LG P1 04.00.02.00 R3779
BMS SW Version LGBMS.01.01.01.00

In the past I got the impression that LG is doing rolling upgrades, so with the feature hitting your ESS I'm hopeful to see it on within in a few weeks (maybe).

Unfortunately the app seems to be little more than a browser so I can only look what is different once I have an upgraded ESS to tinker with.

@fu-zhou
Copy link

fu-zhou commented Sep 8, 2020

I got my update this morning (ESS Home 8) and I had to reset the inverter to factory settings in order to access the installer settings in the EnervuApp again. There came always the message that the settings cannot be accessed because another installer is logged in. First I was afraid (,I was petrified ;-)) that this was a wanted (new) behaviour to limit the access to the app only, but after stopping the mqtt service I still got the same error, but a full reset helped - probably due to new features, incompatible with previous versions. I just wanted to share in case you witness the same behaviour.
The system is currently on:
20200908_220512
@thomasfoxl where does the problem occure you describe/ what doesn't work any more? I did not run into issues yet...

@thomasfoxl
Copy link
Author

The current concept allows to switch fastcharging on or off only. Due to the third available value it's necessary to introduce a new key like "ess/control/charing_mode" = {0, 1, 2}. Right now the function switch_fastcharge causes the system to switch to economic mode no matter if I provide TRUE or FALSE as parameter.

@thomasfoxl
Copy link
Author

image

I have the same version only difference is PCS-SW-Version: "LG P2"

Are you experiencing that battery power is fed into the grid too? The battery load during night is about 350W. 50W is fed into the grid, 300W is used to cover my base load even though the reals base load is only ~100W, so the system looses about 200W which means a very weak efficiency.

@fu-zhou
Copy link

fu-zhou commented Sep 11, 2020

I can tell you a story... I commissioned my system 4 months ago in May and have opened several cases since then - finally ending up with a firmware from November 2019 which I got via email and flashed on the inverter via USB. This "old" firmware was the best (until now) regarding efficiency. It fed power to the grid at night (low amount though) from the battery, but was better than consuming power from the grid with the battery not being empty in the morning when the sun was delivering enough power to charge again. So I tried all the firmware versions since I always could downgrade via USB and sent a report to the LG service with the bugs/ shortcomings from my perspective per firmware. The worst thing in the firmwares later than November 2019 was, that my string with 6 modules stopped the voltage at 210V rather than going down to 180V resulting in power losses. With the current firmware (mentioned above) I'm really quite happy: the 6 Module String goes down to 180 V delivering peak current and performance, partial shading is really handled well = minimum power drop and the balance between battery and grid consumption at night is also running well from what I see until now.
My base load with router, WLAN repeater, fridge, charging phones, TVs in standby, home automation etc. is more in the range of 600 Watts (inkl. LG inverter), but what scares me is that it seems that we have a significantly higher power consumption according to the power meter which came with the LG system than we had before - like 2 to 3 kWh more per day. Either the power meter isn't that accurate - which I doubt - or the PV system has a daily consumption of like 2 to 3 kWh. Which isn't a big deal as long as the power is supplied from the roof...

@thomasfoxl
Copy link
Author

I've added a view lines of code:

  • ess.py: new function to set battery mode (economic, fast, weather forecast)
  • cli.py: new cmdline-parameter for testing battery mode function
  • essmqtt.py: added mqtt support for new function

Unfortunately, I'm new to Git and I didn't manage to bring my local changes to the pull request. I hope I didn't bring a mass into your project so far.

Can you please advice how I can use PyCharm to check in my changes in the local clone to git? Thanks!

@thomasfoxl
Copy link
Author

pyess.zip

@gluap
Copy link
Owner

gluap commented Sep 28, 2020

@thomasfoxl my guess is you committed locally (on your machine) and your commit shows up in your local repo, but you might have forgotten to "git push" your local changes to upload them to your github. Normally I do the commits via pycharm but the push via command line. As far as I can tell in pycharm the git push action would be found under VCS->GIT->Push (provided you already right-click->Commited your changed files to the lokal repo) Would you like me to put the changes in for you or rather gather some experience with doing it yourself?

Your work is very much appreciated and your pull request didn't change anything in the repo which is also likely why it "merged by itsself" - normally I have to accept pull requests.

@thomasfoxl
Copy link
Author

@gluap, thank's for your quick reply! I took my local clone from the master branch but I guess I should push it to the development branch, right? When I compare my version with the dev-version, I see many differences. Can I try to push directly into the master branch?

@gluap
Copy link
Owner

gluap commented Sep 29, 2020

@thomasfoxl feel free to directly push to master. The development branch ist a bit behind and I need to clean it up!

Cheers,
Paul

@thomasfoxl
Copy link
Author

@gluap: I thought everything works fine, until I tried to switch to battery mode "2" which causes a data type error since 2 can't be converted to bool. I modified essmqtt.handle_control to accept strings/int as well, but running into other problems. Once I fixed that I may come back to you regarding git check-in...

@fu-zhou
Copy link

fu-zhou commented Oct 21, 2020

Today I figured out that a new firmware has been pushed onto my system
20201021_215016
No obvious changes from what I can tell up to now, just wanted to let you know.

@gluap
Copy link
Owner

gluap commented Oct 21, 2020

Thank you for reporting this!

side note: I'm kinda jealous, my 5 kW ESS still has the April version. I hope it's not simply lacking the updates because they already stopped updating that hardware generation. I've only had it for a year now. If I don't see an update by January I'll give them a call to see whether there is supposed to be an update.

@fu-zhou
Copy link

fu-zhou commented Oct 21, 2020

Well, maybe the 5 kW system was brought on the market thouroughly tested and fully working, so no need to upgrade while the bigger ones like I have one are - or hopefully were - buggy. I was happy with the August version but for whatever (undocumented) reason additional fixes were necessary, That is the worst part: You can not read about the fixes and what work is in progress/ planned for the next release and I would expect that you can confirm the update through the Enervu App rather than ending up with a new version without a clue what changed.

@fu-zhou
Copy link

fu-zhou commented Nov 7, 2020

Hi again, I wanted to ask if it's possible yet to change the battery charging mode through mqtt? I figured out that charging depending on the weather forecast may end up in a battery not fully charged while having fed power into the grid these days. So during winter time I'd rather set the charging mode to "fast charge" with a script and turn it back to "battery saving" in the summer time. Next question would be: Can the charging mode be changed without stopping the system before? That is interlocked in the Enervu app, you have to turn the system off prior to changing the charging mode.

@thomasfoxl
Copy link
Author

Hi @fu-zhou, unfortunately, I'm too busy to continue with the code changes and testing. Additionally, I'm a python newbie, so it takes way too long for me to fix the issues I'm facing with the MQTT-version. The command line version is already changing the battery charging status. So if you like, I can provide my version containing bugs...

@PanicMan
Copy link

Thanks for your great work!
My ESS is currently at Version 10.05.7092 from 2020-10-12 R1094 and working really good, except of the weather predictive loading... Instead of charging over the noon, it does it from the beginning, when PV is producing and then from 10h feed into the grid... It should do the opposite, first feed in and then charge... My 10kWh Battery is at 10h usually at 90-100% already...
As I am using pyess with OpenHab3 and MQQT, everything works really good, but I would like to control when the ESS will start charging, do you think it could be possible somehow?

@thomasfoxl
Copy link
Author

Hi @PanicMan ,
I already made a feature request at LG-Support because I'd like to control a few things on my own

  • when the battery should charge
  • if it should charge from PV or from grid (interesting if you have an awattar hourly contract and when prices are below 0)
  • when the battery should be used to power the house or the grid (selling to the grid when prices are very high)
  • when power should be taken from grid even though battery SOC > 0 (if you are loading a electric car)

Right now I don't see any chance to solve that with the existing API.

@alfredkrohmer
Copy link
Contributor

@thomasfoxl did you, by chance, get any feedback from LG?

@thomasfoxl
Copy link
Author

@alfredkrohmer no, unfortunately not.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants