From 105b7967db5748fd0384a8f363e520d0187d51cc Mon Sep 17 00:00:00 2001 From: cdnninja Date: Sun, 2 Jun 2024 21:06:09 -0600 Subject: [PATCH] Update binary_sensor.py --- custom_components/yoto/binary_sensor.py | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/custom_components/yoto/binary_sensor.py b/custom_components/yoto/binary_sensor.py index 7614bbc..8fd68d6 100644 --- a/custom_components/yoto/binary_sensor.py +++ b/custom_components/yoto/binary_sensor.py @@ -72,6 +72,12 @@ class YotoBinarySensorEntityDescription(BinarySensorEntityDescription): off_icon="mdi:headphones-off", entity_category=EntityCategory.DIAGNOSTIC, ), + YotoBinarySensorEntityDescription( + key="sleep_timer_active", + name="Sleep Timer", + is_on=lambda player: player.sleep_timer_active, + device_class=BinarySensorDeviceClass.RUNNING, + ), )