Fix binary sensor at Home Connect (#128234)

This commit is contained in:
J. Diego Rodríguez Royo
2024-10-12 11:30:38 +02:00
committed by GitHub
parent 8236a9529f
commit b5a6bb74ce

View File

@@ -41,20 +41,19 @@ REFRIGERATION_DOOR_BOOLEAN_MAP = {
class HomeConnectBinarySensorEntityDescription(BinarySensorEntityDescription): class HomeConnectBinarySensorEntityDescription(BinarySensorEntityDescription):
"""Entity Description class for binary sensors.""" """Entity Description class for binary sensors."""
device_class: BinarySensorDeviceClass | None = BinarySensorDeviceClass.DOOR
boolean_map: dict[str, bool] | None = None boolean_map: dict[str, bool] | None = None
BINARY_SENSORS = ( BINARY_SENSORS = (
BinarySensorEntityDescription( HomeConnectBinarySensorEntityDescription(
key=BSH_REMOTE_CONTROL_ACTIVATION_STATE, key=BSH_REMOTE_CONTROL_ACTIVATION_STATE,
translation_key="remote_control", translation_key="remote_control",
), ),
BinarySensorEntityDescription( HomeConnectBinarySensorEntityDescription(
key=BSH_REMOTE_START_ALLOWANCE_STATE, key=BSH_REMOTE_START_ALLOWANCE_STATE,
translation_key="remote_start", translation_key="remote_start",
), ),
BinarySensorEntityDescription( HomeConnectBinarySensorEntityDescription(
key="BSH.Common.Status.LocalControlActive", key="BSH.Common.Status.LocalControlActive",
translation_key="local_control", translation_key="local_control",
), ),
@@ -76,15 +75,15 @@ BINARY_SENSORS = (
}, },
translation_key="charging_connection", translation_key="charging_connection",
), ),
BinarySensorEntityDescription( HomeConnectBinarySensorEntityDescription(
key="ConsumerProducts.CleaningRobot.Status.DustBoxInserted", key="ConsumerProducts.CleaningRobot.Status.DustBoxInserted",
translation_key="dust_box_inserted", translation_key="dust_box_inserted",
), ),
BinarySensorEntityDescription( HomeConnectBinarySensorEntityDescription(
key="ConsumerProducts.CleaningRobot.Status.Lifted", key="ConsumerProducts.CleaningRobot.Status.Lifted",
translation_key="lifted", translation_key="lifted",
), ),
BinarySensorEntityDescription( HomeConnectBinarySensorEntityDescription(
key="ConsumerProducts.CleaningRobot.Status.Lost", key="ConsumerProducts.CleaningRobot.Status.Lost",
translation_key="lost", translation_key="lost",
), ),