I’m trying to get working my energy panel but i’m stuck at return as my dashboard tells me i’m full solar powered even during night time…
My solar company installed two Wibeee 3 phase meters, one attached to the inbound grid cables and one attached to the solar panels. I get 4 devices and 44 entities from each.
So by what i undesrtand i’m getting separated every phase (3 of them each) and a “general” sensor for each device.
What i’m not getting is HA to calculate as my wibeee webapp does. Wibeee app show the return as negative value, while on the HA i just get wrong information.
For “Grid consumption” i’ve selected GENERAL device, energy sensor ,from Wibeee attached to inbound cables.
For “Solar production” i’ve selected GENERAL device, energy sensor, from Wibeee attached to Solar cables
And last, for “Return to grid” i’ve selected again the GENERAL device, energy sensor, for the Wibeee attached to inbound grid cables…
So, why is my homeassistant counting everything as solar production and not interpreting like…
Example:
for consumtion +2kWh, consumption = 2kWh
for solar +5,5kWh, consumption = -3,5kWh
for return to grid = +3,5kWh
Hope i’ll explain my self… otherwise i’ll try to upload screenshots or something that helps to get the point. Thanks for any help!
So after some work around and having figured it out that i started a discussion without even configured everything from the begging… i’m stuck at this state with “integration” (riemann sum…) :
Thanks mate, and Sorry, i was doing so much trial and error that i uploaded a wrong picture… they are now, and were when the problem started, at “kWh”.
By the way, code used:
Template:
- sensor:
- unique_id: grid_import_export_power
device_class: power
unit_of_measurement: "W"
state_class: measurement
state: >-
{% if states('sensor.wibeee_power_factor_l4') | float < 0 %}
{{ states('sensor.wibeee_active_power_l4') | float * -1 | round(0) }}
{% else %}
{{ states('sensor.wibeee_active_power_l4') | float | round(0) }}
{% endif %}
availability: "{{ not states('sensor.wibeee_active_power_l4') in ('unavailable', 'unknown') and not states('sensor.wibeee_power_factor_l4') in ('unavailable', 'unknown') }}"
attributes:
friendly_name: "Grid import(+) or export(-) power"
- unique_id: grid_import_power
device_class: power
unit_of_measurement: "W"
state_class: measurement
state: "{{ [states('sensor.template_grid_import_export_power') | float, 0] | max | round(0) }}"
availability: "{{ not states('sensor.template_grid_import_export_power') in ('unavailable', 'unknown') }}"
attributes:
friendly_name: "Grid import power"
- unique_id: grid_export_power
device_class: power
unit_of_measurement: "W"
state_class: measurement
state: "{{ [states('sensor.template_grid_import_export_power') | float, 0] | min | abs | round(0) }}"
availability: "{{ not states('sensor.template_grid_import_export_power') in ('unavailable', 'unknown') }}"
attributes:
friendly_name: "Grid export power"