Writing data back to inverter #89
Replies: 5 comments
-
wow, well this is exciting! Can't wait to see if I can completely stop using their app and do this all locally |
Beta Was this translation helpful? Give feedback.
-
This is exciting stuff. I don't have the ability to run Rust apps, but am keen to go completely local with my FoxEss inverter. One thing that would be genuinely useful is if anyone succeeding to set the registers on their inverter could post their firmware and software versions - Then we can determine if a particular version is required for this to all work. |
Beta Was this translation helpful? Give feedback.
-
Looks fab. I'd be happy to test / report but need a bit more of a 'how to guide' for a numpty like me. I'm using HA on an RPi4. It'd be super useful if I could set battery charging times using the HA Octopus Intelligent integration |
Beta Was this translation helpful? Give feedback.
-
Once I get my connection to my H1 moved over to RS485 rather than ethernet this will be an interesting thing to try out - happy to help with testing if needed. Varying the amount of charge I put in the battery overnight to give me "room" to capture excess solar gain when the forecast is sunny would be another helpful use case. Plus of course the potential to have HA automatically get the battery to charge in the cheapest slots for Octopus Agile or similar would be awesome. |
Beta Was this translation helpful? Give feedback.
-
I knocked up a small project to use a USB -> RS485 converter to allow Home Assistant to control the charge times for my inverter. https://github.com/Ashthos/foxess-modbus This does work and I am using it in HA automations. I've included the python scripts I'm using to optimise the charge times depending on the Solcast solar forecast for the next day - they may be useful to someone. A warning to all, however, is that it may be considered 'expert' level. It isn't a point and click installation or configure. |
Beta Was this translation helpful? Give feedback.
-
I only saw yesterday that the charge time registers have been identified, so I've whipped up a quick demo of writing back to these:
https://gist.github.com/welshdave/bec82b4ef4a2795b173a576dffb363d8
It's possible to write back to other registers as well (I've tested limiting the max export). I think anything that's available in remote settings through the cloud app can be changed this way. Be warned though, you can do things with this that you can't through the FoxESS apps (overlapping charge times confirmed to save - didn't wait to see what happens when it hits that time).
If values need to be changed together in the cloud app then they need to be read/written together from code. While you can read the charging time registers individually as input registers, you need to read/write them all together as holding registers.
This opens the door to automatic management of charging/max soc etc without using the FoxESS API.
Beta Was this translation helpful? Give feedback.
All reactions