Oops. Rounded the wrong sensors.
This commit is contained in:
@@ -29,7 +29,7 @@
|
||||
unit_of_measurement: 'W'
|
||||
state: >
|
||||
{% if (states('sensor.line_power_channel_a_power')|float + states('sensor.line_power_channel_b_power')|float + states('sensor.line_power_channel_c_power')|float) > 0 %}
|
||||
{{ states('sensor.line_power_channel_a_power')|float + states('sensor.line_power_channel_b_power')|float + states('sensor.line_power_channel_c_power')|float }}
|
||||
{{ (states('sensor.line_power_channel_a_power')|float + states('sensor.line_power_channel_b_power')|float + states('sensor.line_power_channel_c_power')|float)|round(1) }}
|
||||
{% else %}
|
||||
{{ 0 }}
|
||||
{% endif %}
|
||||
@@ -44,7 +44,7 @@
|
||||
unit_of_measurement: 'W'
|
||||
state: >
|
||||
{% if (states('sensor.line_power_channel_a_power')|float + states('sensor.line_power_channel_b_power')|float + states('sensor.line_power_channel_c_power')|float) < 0 %}
|
||||
{{ (states('sensor.line_power_channel_a_power')|float + states('sensor.line_power_channel_b_power')|float + states('sensor.line_power_channel_c_power')|float) * -1 }}
|
||||
{{ ((states('sensor.line_power_channel_a_power')|float + states('sensor.line_power_channel_b_power')|float + states('sensor.line_power_channel_c_power')|float) * -1 ) | round(1) }}
|
||||
{% else %}
|
||||
{{ 0 }}
|
||||
{% endif %}
|
||||
@@ -60,9 +60,9 @@
|
||||
state: >
|
||||
{% if (states('sensor.power_export')|float(0)) > 0 and (states('sensor.balkonkraftwerk_power')|float(0) - states('sensor.power_export')|float(0)) < 0 %}
|
||||
{% elif (states('sensor.power_export')|float(0)) > 0 and (states('sensor.balkonkraftwerk_power')|float(0) - states('sensor.power_export')|float(0)) > 0 %}
|
||||
{{ (states('sensor.balkonkraftwerk_power')|float(0)) - states('sensor.power_export')|float(0) }}
|
||||
{{ ((states('sensor.balkonkraftwerk_power')|float(0)) - states('sensor.power_export')|float(0)) | round(1) }}
|
||||
{% else %}
|
||||
{{ states('sensor.power_import')|float(0) + states('sensor.balkonkraftwerk_power')|float(0) }}
|
||||
{{ (states('sensor.power_import')|float(0) + states('sensor.balkonkraftwerk_power')|float(0)) | round(1) }}
|
||||
{% endif %}
|
||||
device_class: power
|
||||
state_class: measurement
|
||||
|
Reference in New Issue
Block a user