edalquist / pwrcell_sunspec Goto Github PK
View Code? Open in Web Editor NEWLicense: MIT License
License: MIT License
I would be great to know the actual state of the inverter, pv links and battery and in case of any error on the system receive a notification with a HA automation. Model model_64259.json has good sensors that can be useful in this case.
There is a bug somewhere in the update/write path that can result in dead threads and a stuck app. Currently it requires a restart of the app. Probably need to fix error/exception handling somewhere to ensure errors never bubble all the way up.
Howdy -- oriolism suggested I check out this project.
I have 3 inverters in my system, but only one has a battery. When trying to run main.py
on the inverters with no batteries, the script fails.
If I don't set battery
, main.py
closes with:
Traceback (most recent call last):
File "/opt/pwrcell_sunspec/main.py", line 97, in <module>
app.run(main)
File "/usr/local/lib/python3.9/site-packages/absl/app.py", line 308, in run
_run_main(main, args)
File "/usr/local/lib/python3.9/site-packages/absl/app.py", line 254, in _run_main
sys.exit(main(argv))
File "/opt/pwrcell_sunspec/main.py", line 67, in main
battery=config['pwrcell']['device_ids']['battery'],
KeyError: 'battery'
If I specify battery
as -1, main.py
closes with:
Traceback (most recent call last):
File "/opt/pwrcell_sunspec/main.py", line 97, in <module>
app.run(main)
File "/usr/local/lib/python3.9/site-packages/absl/app.py", line 308, in run
_run_main(main, args)
File "/usr/local/lib/python3.9/site-packages/absl/app.py", line 254, in _run_main
sys.exit(main(argv))
File "/opt/pwrcell_sunspec/main.py", line 80, in main
pwrcell_ha.init()
File "/opt/pwrcell_sunspec/homeassistant.py", line 99, in init
self.__pwrcell.battery.battery[0].W,
AttributeError: 'GeneracPwrCell' object has no attribute 'battery'
What's your tolerance on productionising this? If its your pet project that you're not even sure you want to maintain, I don't want to bombard you with PRs for execution ergonomics. I'm thinking of a few, including utilizing argv (instead of tossing it first-off) to specify configfile, so I can run multiple copies in separate docker containers.
If you want to chat on discord, my handle is AdmiralPete#9678
All the PV Links are reporting wrong decimal values for example 78.0 W instead of 780 W.
Im still testing and so far this app is working great! One thing I am missing is the ability to enable and disable the inverter, pv links and maybe the battery from HA. I think that model 64206 has the option to enable/disable the inverter and model 64211 has the option for the pv links, not sure about the battery.
Hi, can you give me some guide on how to use this project? Im using the sunspect integration in HA but doesn't have all the data from the inverter.
Regards
I currently have a system without PV (just battery backup)? pwrcell.py requires that PV links be identified, and homeassistan.py crashes without a PV link. I've worked around the issue by commenting out the code in homeassistant.py starting at line 142, but it would be great to have a more elegant solution.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.