Add energy monitor using riemann sum algorithm.
This commit is contained in:
@@ -326,6 +326,7 @@ display:
|
||||
id(atorch_current).has_state() ? id(atorch_current).state : NAN,
|
||||
id(atorch_power).has_state() ? id(atorch_power).state : NAN,
|
||||
id(atorch_capacity).has_state() ? id(atorch_capacity).state : NAN,
|
||||
id(atorch_energy_calculated).has_state() ? id(atorch_energy_calculated).state : NAN,
|
||||
id(atorch_temperature).has_state() ? id(atorch_temperature).state : NAN
|
||||
);
|
||||
|
||||
@@ -480,6 +481,19 @@ sensor:
|
||||
name: "${friendly_name} Atorch Dim Backlight"
|
||||
id: atorch_dim_backlight
|
||||
|
||||
- platform: integration
|
||||
name: "${friendly_name} Atorch Energy"
|
||||
id: atorch_energy_calculated
|
||||
sensor: atorch_power
|
||||
time_unit: h
|
||||
unit_of_measurement: "Wh"
|
||||
icon: "mdi:lightning-bolt"
|
||||
device_class: energy
|
||||
state_class: total_increasing
|
||||
accuracy_decimals: 3
|
||||
restore: true
|
||||
integration_method: trapezoid
|
||||
|
||||
text_sensor:
|
||||
- platform: template
|
||||
name: "${friendly_name} OWON Reading"
|
||||
|
||||
Reference in New Issue
Block a user