mirror of
https://github.com/home-assistant/core.git
synced 2025-04-23 16:57:53 +00:00
Add sensors for pellets boiler in ViCare integration (#138563)
* add buffer sensors * remove duplicate sensor * add labels * Bump PyViCare to 2.43.0 * add fuel need sensor
This commit is contained in:
parent
d97194303a
commit
68085ed4f9
@ -29,6 +29,7 @@ from homeassistant.const import (
|
||||
PERCENTAGE,
|
||||
EntityCategory,
|
||||
UnitOfEnergy,
|
||||
UnitOfMass,
|
||||
UnitOfPower,
|
||||
UnitOfPressure,
|
||||
UnitOfTemperature,
|
||||
@ -635,6 +636,38 @@ GLOBAL_SENSORS: tuple[ViCareSensorEntityDescription, ...] = (
|
||||
device_class=SensorDeviceClass.TEMPERATURE,
|
||||
state_class=SensorStateClass.MEASUREMENT,
|
||||
),
|
||||
ViCareSensorEntityDescription(
|
||||
key="buffer_mid_top_temperature",
|
||||
translation_key="buffer_mid_top_temperature",
|
||||
state_class=SensorStateClass.MEASUREMENT,
|
||||
device_class=SensorDeviceClass.TEMPERATURE,
|
||||
native_unit_of_measurement=UnitOfTemperature.CELSIUS,
|
||||
value_getter=lambda api: api.getBufferMidTopTemperature(),
|
||||
),
|
||||
ViCareSensorEntityDescription(
|
||||
key="buffer_middle_temperature",
|
||||
translation_key="buffer_middle_temperature",
|
||||
state_class=SensorStateClass.MEASUREMENT,
|
||||
device_class=SensorDeviceClass.TEMPERATURE,
|
||||
native_unit_of_measurement=UnitOfTemperature.CELSIUS,
|
||||
value_getter=lambda api: api.getBufferMiddleTemperature(),
|
||||
),
|
||||
ViCareSensorEntityDescription(
|
||||
key="buffer_mid_bottom_temperature",
|
||||
translation_key="buffer_mid_bottom_temperature",
|
||||
state_class=SensorStateClass.MEASUREMENT,
|
||||
device_class=SensorDeviceClass.TEMPERATURE,
|
||||
native_unit_of_measurement=UnitOfTemperature.CELSIUS,
|
||||
value_getter=lambda api: api.getBufferMidBottomTemperature(),
|
||||
),
|
||||
ViCareSensorEntityDescription(
|
||||
key="buffer_bottom_temperature",
|
||||
translation_key="buffer_bottom_temperature",
|
||||
state_class=SensorStateClass.MEASUREMENT,
|
||||
device_class=SensorDeviceClass.TEMPERATURE,
|
||||
native_unit_of_measurement=UnitOfTemperature.CELSIUS,
|
||||
value_getter=lambda api: api.getBufferBottomTemperature(),
|
||||
),
|
||||
ViCareSensorEntityDescription(
|
||||
key="buffer main temperature",
|
||||
translation_key="buffer_main_temperature",
|
||||
@ -891,6 +924,15 @@ GLOBAL_SENSORS: tuple[ViCareSensorEntityDescription, ...] = (
|
||||
entity_category=EntityCategory.DIAGNOSTIC,
|
||||
value_getter=lambda api: api.getBatteryLevel(),
|
||||
),
|
||||
ViCareSensorEntityDescription(
|
||||
key="fuel_need",
|
||||
translation_key="fuel_need",
|
||||
state_class=SensorStateClass.MEASUREMENT,
|
||||
entity_category=EntityCategory.DIAGNOSTIC,
|
||||
native_unit_of_measurement=UnitOfMass.KILOGRAMS,
|
||||
value_getter=lambda api: api.getFuelNeed(),
|
||||
unit_getter=lambda api: api.getFuelUnit(),
|
||||
),
|
||||
)
|
||||
|
||||
CIRCUIT_SENSORS: tuple[ViCareSensorEntityDescription, ...] = (
|
||||
|
@ -338,6 +338,18 @@
|
||||
"buffer_top_temperature": {
|
||||
"name": "Buffer top temperature"
|
||||
},
|
||||
"buffer_mid_top_temperature": {
|
||||
"name": "Buffer mid top temperature"
|
||||
},
|
||||
"buffer_middle_temperature": {
|
||||
"name": "Buffer middle temperature"
|
||||
},
|
||||
"buffer_mid_bottom_temperature": {
|
||||
"name": "Buffer mid bottom temperature"
|
||||
},
|
||||
"buffer_bottom_temperature": {
|
||||
"name": "Buffer bottom temperature"
|
||||
},
|
||||
"buffer_main_temperature": {
|
||||
"name": "Buffer main temperature"
|
||||
},
|
||||
@ -478,6 +490,9 @@
|
||||
},
|
||||
"spf_heating": {
|
||||
"name": "Seasonal performance factor - heating"
|
||||
},
|
||||
"fuel_need": {
|
||||
"name": "Fuel need"
|
||||
}
|
||||
},
|
||||
"water_heater": {
|
||||
|
Loading…
x
Reference in New Issue
Block a user