No, the integration must be added as usual, the configuration.yaml is only to create the entities for the energy dashboard
ok, so I think I have to dive deeper into that template stuff before moving on.
not necessarily, you have to install the integration at first and then you can add a template to create the entities to add on the energy dashboard.
You can use the code on the first post, it works well and if you have HA in english it should be only a copy and paste.
Anyway once you get it works, you can customize it like I did, adding stuff, or give a better format to the values etcâŚ
The default entity_ids the Fronius integration sets up have changed meanwhile. But it should be trivial to find the according ones. Copy & paste wonât work out of the box though.
Thanks for the clarification, thatâs why I used âshouldâ .
Anyway, at the beginning I copied and paste the code at first post and worked, of course I had to add more stuff since I have 2 inverter but - entitiesâ names in Italian a part - I didnât have any big issues with it.
I think my problem is, that I donât know where to paste the code. I pasted it to my configuration.yaml which, obviously donât work? I also donât understand if it is needed to ad the âhelpersâ. I could not find anything about that in the first post.
I used âpackagesâ folder.
Inside of home assistant installation folder i created a subfolder called âpackagesâ.
Here I added a file named fotovoltaico.yaml (fotovoltaico is the italian word for solar plant), and I pasted the code above.
To enable the package folder you have to add this line to configuration.yaml
homeassistant:
packages: !include_dir_named packages
For the helpers there is a section on gui. Settings â Devices & Services â Helpers (last tab on top)
I did it so but maybe there is a better way
âHelpersâ came to existence long after the first post in this thread. You can configure a Riemann sum integration by yaml or - now alternatively - via a helper.
Thanks for your help!
What I meanwhile did (basically through trial and error) is:
- created the sensors by pasting this in the configuration.yaml (@crc-error79 I read about the packages folder, which makes sense to me, will be the next step).
template:
- sensor:
- name: "Battery Power Charging"
unit_of_measurement: W
device_class: power
state: "{{ max(0, 0 - states('sensor.solarnet_leistung_von_der_batterie') | float(default=0)) }}"
- name: "Battery Power Discharging"
unit_of_measurement: W
device_class: power
state: "{{ max(0, states('sensor.solarnet_leistung_von_der_batterie') | float(default=0)) }}"
- name: "Power Photovoltaics"
unit_of_measurement: W
device_class: power
state: "{{ states('sensor.solarnet_power_photovoltaics') | float(default=0) }}"
Then I created the two helpers for battery charging and discharging. I think Iâm on a good way now.
Yeah! You are getting data to use in the energy dashboard!
Now - this is the boring part - you must only be patience because it riemann sum requires time, many time
I think that by tomorrow you should be able to confront that data with the one from solarweb app to see if it works correctly
Only thing is that Iâm not sure ist the units are ok?! I guess it should be kW, resp. kWh ?! Setting up the riemann integration, I choose ânoneâ instead og âkâ as prefix. Is this correct?
It is ok, thatâs the same error I did at the firstâŚ
The energy dashboard will do the conversion Wh â kWh for you
I think there is still a mismatch concerning the units. The battery has been loaded over the day up to 82% (capacity 10.2 kWh).
Shouldnât it be 9.63 kWh in the first picture?!
Had you add the two entities (helper - Riemann sum) for battery (âchargingâ and âin useâ) to the energy dashboard?
Yes, I created a helper for charge and one for discharge.
On the last picture you posted charge and discharge are 0, it seems that the helper are not set here, could you check? âŚbecause on the other pictures you have values for the battery
I still believe, there is a fault with the units.
This is the entity,
I used to create the two sensors:
Then, I created the two riemann summ integration:
These are correct⌠it is strange you have no dataâŚ
When you added it? Because it need time to populate data
Mine are also in Wh (the missing data in graphs is because today I powered off the server for maintenance)
@FlyByWire
Just noticed, are you sure that the Riemann sum are done with the right sensors?
Because it is strange that the update is almost the same for both: charge and discharge.
If you see mine data now I am using the battery so the âbatteria - in usoâ (battery in use) is updated to few seconds ago, but âbatteria - ricaricaâ (battery in charge) has the last update 1 hour ago (when the panels were in production)