Integration Solar inverter huawei 2000L

ah ok, so more connections are not possible? as my FHEM is also still conntected to this device and reading (as i am currently in the transition phase from fhem to homeassistant :slight_smile: )
ā€¦
that does the trickā€¦ after disabling the connection from FHEM, i can now see the current power of the inverterā€¦ but only this value, not moreā€¦

Other values are in attribute of this entity. So you will see only one entity with current power, but in attributes of this entity you will see more information.

@Emilv2,

Today there is a new release of HA.
It contains a new feature ā€œEnergyā€ dashboard, i like to select Huawei inverter but itā€™s not available. Is there a way you can make it available by updating the add-on?

1 Like

Iā€™m testing it for few days (beta) and the only way (few days ago) was to use utility meter.

1 Like

Finally managed to get this intergration install, can see in the logs:

2021-08-05 14:23:02 WARNING (SyncWorker_1) [homeassistant.loader] We found a custom integration huawei_solar which has not been tested by Home Assistant. This component might cause stability problems, be sure to disable it if you experience issues with Home Assistant
...
2021-08-05 14:23:14 INFO (SyncWorker_7) [homeassistant.util.package] Attempting install of huawei-solar>=1.1.0,<2.0.0
...
2021-08-05 14:23:22 INFO (MainThread) [homeassistant.components.sensor] Setting up sensor.huawei_solar
...

I canā€™t see any sensors in HA tho.

Reading through this forum too, not sure I am setting this up correctly. My inverter is s SUN2000-5KTL-L1 with built in Wi-Fi and is fully up-to-date.
Will this intergration connect to it directly over my WiFi network (not itā€™s own WiFi).

Thanks!

@ligeza Can you please share your config for the utility meter? Iā€™ve tried as below, but I think Iā€™m missing something.

utility_meter:
  energy:
    source: sensor.sun2000_8ktl_m1
    cycle: monthly
    name: Monthly Energy Meter

@seanmccabe try to use the python library via terminal on your PC first, to see if you get any readings, there is an example in my postings above. Or maybe you just have to search for ā€œsun2000ā€ in the dev tools panels, only one sensor will appear after this integration with the model name of your inverter that will have the production of your inverter as a value. The rest of the params of the inverters are attributes of that sensor and you must create additional sensors in your config for them to appear, there are examples above.

Utility meter donā€™t count correctly for me,

utility_meter:
  dzienne_zuzycie:
    source: sensor.energy_used
    cycle: daily
  miesieczne_zuzycie:
    source: sensor.energy_used
    cycle: monthly
  miesieczna_produkcja:
    source: sensor.total_yield
    cycle: monthly
  roczne_zuzycie:
    source: sensor.energy_used
    cycle: yearly  
  roczna_produkcja:
    source: sensor.total_yield
    cycle: yearly
  roczne_zuzycie_5maj:
    source: sensor.energy_used
    cycle: yearly  
    offset:
      days: 125  

I found other way:
add attribute in customization:

1 Like

Thank you!
One thing I didnā€™t search for was the model, its in there and working :slight_smile:

1 Like

I used the platform:integration, seems to be working fine. I think it would be more accurate to use the ā€˜Daily yieldā€™ attribute (and transform it to Monthly yield) as kWh generated could differ a lot on cloudy days. For now, platform:integration shows 9.14 and ā€˜Daily yieldā€™ is 9.18, the difference is pretty small.

- platform: integration
  source: sensor.sun2000_12ktl_m2
  name: solar_kwh
  unit_prefix: k
  round: 2

also had to add this to customize.yml:

sensor.sun2000_12ktl_m2:
  device_class: power
1 Like

Try customize sensor

homeassistant:
  customize_glob:
   sensor.name_sensor_total_*: 
     last_reset: '1970-01-01T00:00:00+00:00'
     device_class: energy
     state_class: measurement

Second day i try setup new dashboard ā€œEnergyā€ without lucky.
In all combos i see ā€œYou donā€™t have any statisticsā€ like this.

image

My configuration is:

and i added already attributes: last_reset, device_class, state_class like this.

I also have properly working

What else shut i do to see at last ā€œstatisticsā€ in new dashboard ā€œEnergyā€ (combos) ?

Did you try unit_of_measurement: kWh?

1 Like

Energy feature is nice, but donā€™t forget that for graphs Grafana still rules , I recommend everyone to play a little with Grafana, you can create some really cool and informative dashboards. ( https://www.youtube.com/channel/UCXEa_Gzl2zjhb7K6xflyrWQ has an awesome video explaining how to enable influx and grafana in HASS.
See mine below, will improve it a lot after installing the smart meter also.

1 Like

what does name_sensor_total_: * reference?

This worked for me:

customize.yaml:

sensor.sun2000_5ktl_l1:
  device_class: power

sensor.yaml:

- platform: template
  sensors:
    pv_total_yield:
      friendly_name: "Solar kWh"
      value_template: "{{ state_attr('sensor.sun2000_5ktl_l1', 'total_yield') }}"
      unit_of_measurement: "kWh"
      device_class: energy
      icon_template: mdi:solar-power

Iā€™m not sure what value the energy integration wants, whether it wants daily, or something smaller, like current production, if anyone can shed any light on that?

Hey, it works great but after the recent update we now have energy, can figure out how to fit in no sensors found

any idea on what needs to be changed to fit it in?
tried:

consumption_home_from_solar_now

  • platform: template
    sensors:
    consumption_home_from_solar_now:
    friendly_name: ā€œconsumption home from solar nowā€
    unit_of_measurement: ā€œWhā€
    last_reset: ā€˜1970-01-01T00:00:00+00:00ā€™
    device_class: energy
    state_class: measurement
    icon_template: mdi:solar-power
    value_template: ā€˜{{ ((states.sensor.pv_input_power.state | float ) - (states.sensor.export_to_grid_now.state | float )) | round(1) }}ā€™

but still not foundā€¦

For me itā€™s working in this way:

1 Like

bingo !!!. Thanks.
kWh works.

all good mate, was able to update via customize menu
unit_of_measurement: ā€œkWhā€
last_reset: ā€˜1970-01-01T00:00:00+00:00ā€™
device_class: energy

hey mate why you use total_yield? notpv_input_power ? isnt that need to be current values or i misunderstood it ?