mirror of
https://github.com/home-assistant/core.git
synced 2025-07-22 20:57:21 +00:00
Add device error sensor to ViCare integration (#142605)
* add error sensor * remove translation
This commit is contained in:
parent
32da8c52f7
commit
f519b20495
@ -112,6 +112,11 @@ GLOBAL_SENSORS: tuple[ViCareBinarySensorEntityDescription, ...] = (
|
||||
device_class=BinarySensorDeviceClass.RUNNING,
|
||||
value_getter=lambda api: api.getOneTimeCharge(),
|
||||
),
|
||||
ViCareBinarySensorEntityDescription(
|
||||
key="device_error",
|
||||
device_class=BinarySensorDeviceClass.PROBLEM,
|
||||
value_getter=lambda api: len(api.getDeviceErrors()) > 0,
|
||||
),
|
||||
)
|
||||
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user