Set SmartThings delta energy to Total (#139474)

pull/139539/head
Joost Lekkerkerker 2025-02-28 20:03:24 +01:00 committed by GitHub
parent bf27ccce17
commit 086c91485f
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 13 additions and 13 deletions

View File

@ -596,7 +596,7 @@ CAPABILITY_TO_SENSORS: dict[
SmartThingsSensorEntityDescription(
key="deltaEnergy_meter",
translation_key="energy_difference",
state_class=SensorStateClass.TOTAL_INCREASING,
state_class=SensorStateClass.TOTAL,
device_class=SensorDeviceClass.ENERGY,
native_unit_of_measurement=UnitOfEnergy.KILO_WATT_HOUR,
value_fn=lambda value: value["deltaEnergy"] / 1000,

View File

@ -582,7 +582,7 @@
}),
'area_id': None,
'capabilities': dict({
'state_class': <SensorStateClass.TOTAL_INCREASING: 'total_increasing'>,
'state_class': <SensorStateClass.TOTAL: 'total'>,
}),
'config_entry_id': <ANY>,
'config_subentry_id': <ANY>,
@ -620,7 +620,7 @@
'attributes': ReadOnlyDict({
'device_class': 'energy',
'friendly_name': 'AC Office Granit Energy difference',
'state_class': <SensorStateClass.TOTAL_INCREASING: 'total_increasing'>,
'state_class': <SensorStateClass.TOTAL: 'total'>,
'unit_of_measurement': <UnitOfEnergy.KILO_WATT_HOUR: 'kWh'>,
}),
'context': <ANY>,
@ -1011,7 +1011,7 @@
}),
'area_id': None,
'capabilities': dict({
'state_class': <SensorStateClass.TOTAL_INCREASING: 'total_increasing'>,
'state_class': <SensorStateClass.TOTAL: 'total'>,
}),
'config_entry_id': <ANY>,
'config_subentry_id': <ANY>,
@ -1049,7 +1049,7 @@
'attributes': ReadOnlyDict({
'device_class': 'energy',
'friendly_name': 'Aire Dormitorio Principal Energy difference',
'state_class': <SensorStateClass.TOTAL_INCREASING: 'total_increasing'>,
'state_class': <SensorStateClass.TOTAL: 'total'>,
'unit_of_measurement': <UnitOfEnergy.KILO_WATT_HOUR: 'kWh'>,
}),
'context': <ANY>,
@ -1835,7 +1835,7 @@
}),
'area_id': None,
'capabilities': dict({
'state_class': <SensorStateClass.TOTAL_INCREASING: 'total_increasing'>,
'state_class': <SensorStateClass.TOTAL: 'total'>,
}),
'config_entry_id': <ANY>,
'config_subentry_id': <ANY>,
@ -1873,7 +1873,7 @@
'attributes': ReadOnlyDict({
'device_class': 'energy',
'friendly_name': 'Refrigerator Energy difference',
'state_class': <SensorStateClass.TOTAL_INCREASING: 'total_increasing'>,
'state_class': <SensorStateClass.TOTAL: 'total'>,
'unit_of_measurement': <UnitOfEnergy.KILO_WATT_HOUR: 'kWh'>,
}),
'context': <ANY>,
@ -2408,7 +2408,7 @@
}),
'area_id': None,
'capabilities': dict({
'state_class': <SensorStateClass.TOTAL_INCREASING: 'total_increasing'>,
'state_class': <SensorStateClass.TOTAL: 'total'>,
}),
'config_entry_id': <ANY>,
'config_subentry_id': <ANY>,
@ -2446,7 +2446,7 @@
'attributes': ReadOnlyDict({
'device_class': 'energy',
'friendly_name': 'Dishwasher Energy difference',
'state_class': <SensorStateClass.TOTAL_INCREASING: 'total_increasing'>,
'state_class': <SensorStateClass.TOTAL: 'total'>,
'unit_of_measurement': <UnitOfEnergy.KILO_WATT_HOUR: 'kWh'>,
}),
'context': <ANY>,
@ -2865,7 +2865,7 @@
}),
'area_id': None,
'capabilities': dict({
'state_class': <SensorStateClass.TOTAL_INCREASING: 'total_increasing'>,
'state_class': <SensorStateClass.TOTAL: 'total'>,
}),
'config_entry_id': <ANY>,
'config_subentry_id': <ANY>,
@ -2903,7 +2903,7 @@
'attributes': ReadOnlyDict({
'device_class': 'energy',
'friendly_name': 'Dryer Energy difference',
'state_class': <SensorStateClass.TOTAL_INCREASING: 'total_increasing'>,
'state_class': <SensorStateClass.TOTAL: 'total'>,
'unit_of_measurement': <UnitOfEnergy.KILO_WATT_HOUR: 'kWh'>,
}),
'context': <ANY>,
@ -3332,7 +3332,7 @@
}),
'area_id': None,
'capabilities': dict({
'state_class': <SensorStateClass.TOTAL_INCREASING: 'total_increasing'>,
'state_class': <SensorStateClass.TOTAL: 'total'>,
}),
'config_entry_id': <ANY>,
'config_subentry_id': <ANY>,
@ -3370,7 +3370,7 @@
'attributes': ReadOnlyDict({
'device_class': 'energy',
'friendly_name': 'Washer Energy difference',
'state_class': <SensorStateClass.TOTAL_INCREASING: 'total_increasing'>,
'state_class': <SensorStateClass.TOTAL: 'total'>,
'unit_of_measurement': <UnitOfEnergy.KILO_WATT_HOUR: 'kWh'>,
}),
'context': <ANY>,