I’ve been trying to find a way to get my solar panels production to show up in the Home Assistant Energy Dashboard, but haven’t been able to figure out a way to do it.
The problem is, that my solar inverter is too old to provide any direct way to integrate it with HA. The only thing I have is a cloud service provided by the company that installed my panels, which includes an API I can use to get my current production values. So I created a Restful Sensor to do just that:
platform: rest
resource: "*URL*"
name: "Solar power"
value_template: "*Code*"
device_class: energy
unit_of_measurement: "W"
unique_id: "Solar_Production"
state_class: total
The sensor itself is working fine, and I can see its data in the Statistics tab in the Developers Tools page. It shows a nice graph with accurate numbers.
I’ve tried various combinations of device_class (power/energy) and state_class (total/measurement) with no luck. The UI says that the sensor should report Wh, so I tried that too. No luck. I just couldn’t get the sensor to show up in the Energy Dashboards sensor list for Solar Production.
So does anyone have any ideas how to I could get this working? The value I get from the API is the current power of the array in watts. Is it even possible to get Home Assistant to use this kind of data in the Energy Dashboard?