Glad to find this topic! I was able to configure Modbus in confuguration.yaml and get data from my GEN24 and Smartmeter Modbus. I allready can see the data in developer section and use sensors in my own cards. But can please anybody tell me, how to use the data as entity option for energy dashboard? I’m new with Home Assistant but it seems available options for this page has to be configured somewhere else?
Second Question: Is there some dokumentation of modbus sensor adresses for GEN24? I’m searching for the total PV production value.
Do i have to do this in configuration like this?
# Adding Sensor for "reading_energy_main_meter"
template:
- sensor:
- name: "Modbus Energy Main Meter"
unit_of_measurement: "W"
state: {{ states('sensor.reading_energy_main_meter') }}
Because in developer area of HA i’m allready getting correct values.
But I am not able to to set this in Energy Dashboard Grid Consumption. Because this entity is missing there inside option dropdown. Ho to add this there? Any suggestions?
My goal is to set the minimum soc on gen24 to ‚100‘ to ensure that the byd battery is not used during electric vehicle charging. After it is charged I want to set the minimum soc back to ‚5‘. This won’t work via json api but I guess it should work with modbus tcp. But to be honest: never did something with modbus and I am absolutely unsure if it should generally work and if so how.
Hello All,
just a quick heads-up: I installed this morning Core 2023.8.3 and it broke the Fronius Modbus integration for me. As I did not have time to analyze the issue I restored to 2023.8.2. A look into the change log of 2023.8.3 showed some chagnes to the modbus integration, that may effect this configuration here.
Just as a heads-up to at least create a backup when moving to 2023.8.3 in case you run into the some issue.
Hi all,
I have been using Home Assistant for +7 years now, and got a Gen24 inverter half a year ago.
Everything is perfectly integrated, I can change everything from either NodeRED Modbus-Flex-Write nodes or Home Assistant modbus service calls and perfectly read out everything. One thing that continues to nag me, is whenever I set the “StorCtl_Mod” setting (40347, the one that enables or disable the use of the In/OutWRte settings - and address is tripple checked). Whenever I change the value to “3” to active both limits, it keeps the setting for a few seconds, and afterwards resets it to 0, so no limits is enabled.
It doesn’t matter if I have Battery Management enabled in Fronius administrative interface or have disabled / removed all the settings for time-dependent battery control. It is the only setting that gets overwritten, and kinda annoys me as I wan’t to control charge/discharge to perfection during the day, if theres cheap energy and no sun - but still wan’t to keep zero export with grid.
Anyone knowing what is going on and can help me out on this?
I’ve found lots of “samples” that does work for other people, so seems to be a setting in the inverter that I’ve missed. First time I’ve ever given up
You were 100% correct on you assumption. Got total control on the battery charge/discharge now - thank you so much! Really appreciate your help. Never saw or found the connection and dependability anywhere else.
Just got confused - you replied to my post and wrote the name of the helper to my post
Are you interested in my work? Your name indicates you could be a dane? (as I am).
I don’t think the entire work, combined in NodeRED and Home Assistant fit in a short post in here. Maybe we could chat and show work on mail etc? Can try and show some pictures here:
Rather annoyed by Modbus in Home Assistant now. Considering moving everything to node-red, as all my battery management is broken … now, that I am on my fourth day with Tibber …
@steffanlm, would you probably share your flows? Data gathering looks like a heck of work you put into this.
Hey Steffan,
that looks like a ton of great work. I’m still struggling to get battery control right with Node and HA. Really interested in your flows. Could you share them?
Lots of the other nodes has been refactored and are primarily used as very specific calculations for our house, and most can only be used coherent with my other flows and specific data from Home Assistant.
Hope the above gives you some ideas - and if you find anything not working out, please write so I can change it
Wow! Great thread, I’m happy I found it - and thanks to everyone posting!
I’m in a situation were I want to charge the battery on low prices, and use it during peak hours… Same as many of you here. I’ve just setup the Sunspec integration, but question is - does it provide the same functions as a manual YAML file? I haven’t yet found the settings to control the battery…
Any advice would be greatful! I don’t want to dig deep in the wrong direction.
Hi and welcome to this thread
The Sunspec integrations, as far as I’m concerned, does only support reading registers and not writing.
Which means you’ll have to either use NodeRED with the Modbus TCP palettes or use Modbus TCP inside Home Assistant to write to the registers.
Keep in mind, that theres some restraints in some of the writeable registers, especialy the battery power commands and storage mode (InWRte, OutWRte and StorCtl_Mod), from the inverter register map, it states:
Blockquote
Please be aware that setting an invalid power window will result in a modbus exception 3 (ILLEGAL DATA VALUE).
Invalid power windows are all windows where condition:
((StorCtl_Mod == 3) AND ((-1) * InWRtg > OutWRtg))
evaluates to true.
This can happen for example if two negative values are written into InWRtg and OutWRtg and both limits are activated by StorCtl_Mod = 3.
Blockquote