Hi
This is the 4 part series on my OpenHAB excperience, vision for improving OH and lately integrating Ecoflow devices, and migration to OH4.
So the topic is mainly focused on Ecoflow integration and some coments on my setup and vision/ recomendations for future openhab upgrades, at integration workflow on config files.
This multi content post is not quite up to convention, but we will seperate topics if required, this is my folow up as i didnt post a while and more questions arised.
While first i am sharing my Ecoflow project for others to test.
1.EcoFlow
I enjoy keeping an eye on the projects from Cody at WranglerStar Youtube channel, he does great off grid projects and he got me familiar with Ecoflow powerstations and solar equipment.
I have 2 EF devices, River Powerstation and Sloar microinverter as the new addition for balcony solar.
I am exploring the solutions that they offer with conectivity and automation.
They offer Cloud API, but dang i want shit out of the cloud and local control, so any ideas what can be done for River 2 Max and the Powerstream.
For now i share the API bridge to MQTT, that is based on API entities documented on Github HASS IO Ecoflow
Here is the code thar runs as API client and publishes MQTT metrics to local OH server.
It requires setting key and secret of Developer acount token and serial_number of the device.
Ecoflow_V9_clean.py.txt (8.9 KB)
It is done partialy by AI and i only did some fixes to entities, so thanks to AI for help.
So requirements are mqtt broker on server pc, and python 3 with libreries like paho-mqtt…
There is a slight bug that MQTT seems not to reconect if script looses connection to MQTT breoker, so advise apriciated how to fix it.
I run the script as a service on linux by systemd, by foloving this tutorial Automating Python Scripts with Systemd
Then comes the part i become anoyed of all the copy pasting and typing to make congig files for OH
So i use AI again to generate openhab configs. And fighting with AI to make it right, deciding when to step in to fix manually and so on.
Writing MQTT.things, Ecoflow.items and making sitemap entries, icons, and such.
Solar Items file Ecoflow_Solar.items.txt (4.4 KB)
River and Solar Sitemap snippet Sitemap elements EcoFlow River 2 and Solar.txt (10.3 KB)
MQTT things snippet Things mqtt EF_R2M and EF_Solar.txt (7.8 KB)
Pwerstation Items file Ecoflow.items.txt (3.4 KB)
Powerstation Sitemap file ecoflow_river.sitemap.txt (6.9 KB)
I feel it as ground breaking news, that auto integration is posible, as i see it takes way too much time to integrate devices and then i don’t bother unless there is something as exciting as Ecoflow gear, and then also i used AI burned it into the ground with data limits, as it makes misktakes, then i fix some and stuff it into another acount to finally get results i wanted, and then i customized it to finally get the dasboard bellow.
Sitemap River 2 max
Sitemap Ecoflow Solar inverter
Here is my amazing Power Monitoring Display, that swohs curent on 3 pases in house and also shows solar power in right chart below, 82 meaning 82% of full solar power 650W out of 800w max. It’s a simulator picture for beter visibility. It is a Nextion display powered by raw meter data from MQTT and also OpenHAB procesed data of max current. Below thin lines are house load and solar power.
It’s one ofe my biggest projects casue of the electrical overlaod situations visible on picture in L3.
2. Vision on imporving OH
Openhab is constantly upgrading and evolving but still there is all the work to be done on manually configuring each device, i wish i could make device templates that can be used to connect more similar devices with minimal effort like add device rename and done.
Here the openhab in VS Code can be improved with some more workflow automation like it does generating Items from things, but it lacks putting all items in sitemap in one go, lacks making MQTT things from MQTT broker data and such so it is like AI, but without noisy decisions it is precise based on data it gets,
I did a project with Openhab config Builder for my MQTT devices.
It actually reads mqtt topics and values and generates all the things, items, and builds sitemap, it is like black magic on steroids, but it uses dated rules for CSV parsing i used on legacy ESP32 devices, anyhow, i may upgrade it some day, as that is what Home Automation is, i feel it is mandatory automating the integration of devices, then you do all the custom work on automating and inter operation.
The workflow automation is a vision that i plan, is there anything similar happening that i am unavare of, mainly for MQTT, besides HA autodiscovery, that only does half of the stuff as since OH2.5 there is no auto items generation, why a downgrade??
3. My Server situation
And my server in need for cleanup of OH rules and VLC encodes grinding hard at all the data, asking for maintenence idk whatis the cause, but OH needs that exact task manager/rule manager tool to see what script uses what resources, that ttop is no good to see rule names and cpu usage, disk usage, net usage and such…Possibly i pussh it too much, or some bad code idk, but its hard to debug when no errors, just lots of data processing and Influx DB seems heavy on querries.
I built whole dashboard to manage what needs procesing to test load , so cleanup is in progress.
4. Migration to OH4
I am still migrating all the stuff to OH4, its lots of devices and the milestone is that both run for all diagnostics, while the old one is the automation guy.
The new N100 mini pc is running without Influx DB just on rrd4j but i wonder if rrd4j is wearing SSD more than influxDB, as i constantly agregating old data, that also meses up some discrete values, posibly i need to learn how to configure it in multy categories?
So the OH 2.5 is still the grandpa in demand, as the new guy isn’t cutting it yet in all the tasks all the new bindings like Luxtronik and more needed rewriting config code.
So is OH2.5 still secure, considering it is patched for log4j., i mean it is mainly offline from cloud as the cloud connector semms broken, anyow i use VPN.
Thanks for reading
All welcome to test ecoflow API integration project and coment on my thoughts and situation.
Cheers
Matej