Oops. Rounded the wrong sensors.
This commit is contained in:
parent
1ade598c97
commit
8b43bf239b
@ -74,7 +74,7 @@
|
|||||||
source: sensor.power_import
|
source: sensor.power_import
|
||||||
name: energy_import_sum
|
name: energy_import_sum
|
||||||
unit_prefix: k
|
unit_prefix: k
|
||||||
round: 1
|
round: 2
|
||||||
method: left
|
method: left
|
||||||
|
|
||||||
# Sensor for Riemann sum of energy export (W -> Wh)
|
# Sensor for Riemann sum of energy export (W -> Wh)
|
||||||
@ -82,7 +82,7 @@
|
|||||||
source: sensor.power_export
|
source: sensor.power_export
|
||||||
name: energy_export_sum
|
name: energy_export_sum
|
||||||
unit_prefix: k
|
unit_prefix: k
|
||||||
round: 1
|
round: 2
|
||||||
method: left
|
method: left
|
||||||
|
|
||||||
# Sensor for Riemann sum of energy consumption (W -> Wh)
|
# Sensor for Riemann sum of energy consumption (W -> Wh)
|
||||||
@ -90,5 +90,5 @@
|
|||||||
source: sensor.power_consumption
|
source: sensor.power_consumption
|
||||||
name: energy_consumption_sum
|
name: energy_consumption_sum
|
||||||
unit_prefix: k
|
unit_prefix: k
|
||||||
round: 1
|
round: 2
|
||||||
method: left
|
method: left
|
||||||
|
@ -29,7 +29,7 @@
|
|||||||
unit_of_measurement: 'W'
|
unit_of_measurement: 'W'
|
||||||
state: >
|
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 %}
|
{% 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 %}
|
{% else %}
|
||||||
{{ 0 }}
|
{{ 0 }}
|
||||||
{% endif %}
|
{% endif %}
|
||||||
@ -44,7 +44,7 @@
|
|||||||
unit_of_measurement: 'W'
|
unit_of_measurement: 'W'
|
||||||
state: >
|
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 %}
|
{% 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 %}
|
{% else %}
|
||||||
{{ 0 }}
|
{{ 0 }}
|
||||||
{% endif %}
|
{% endif %}
|
||||||
@ -60,9 +60,9 @@
|
|||||||
state: >
|
state: >
|
||||||
{% if (states('sensor.power_export')|float(0)) > 0 and (states('sensor.balkonkraftwerk_power')|float(0) - states('sensor.power_export')|float(0)) < 0 %}
|
{% 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 %}
|
{% 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 %}
|
{% 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 %}
|
{% endif %}
|
||||||
device_class: power
|
device_class: power
|
||||||
state_class: measurement
|
state_class: measurement
|
||||||
|
Loading…
Reference in New Issue
Block a user