From 8bfd5e4d06a353fa34472ada8780f148a5b32c74 Mon Sep 17 00:00:00 2001 From: fOmey Date: Sun, 24 Oct 2021 07:44:22 +1100 Subject: [PATCH] Add switch platform to Tuya Light (dj) devices (#58196) Co-authored-by: Franck Nijhof --- homeassistant/components/tuya/switch.py | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/homeassistant/components/tuya/switch.py b/homeassistant/components/tuya/switch.py index d27fe764541..95688f7dc78 100644 --- a/homeassistant/components/tuya/switch.py +++ b/homeassistant/components/tuya/switch.py @@ -64,6 +64,17 @@ SWITCHES: dict[str, tuple[SwitchEntityDescription, ...]] = { entity_category=ENTITY_CATEGORY_CONFIG, ), ), + # Light + # https://developer.tuya.com/en/docs/iot/f?id=K9i5ql3v98hn3 + "dj": ( + # There are sockets available with an RGB light + # that advertise as `dj`, but provide an additional + # switch to control the plug. + SwitchEntityDescription( + key=DPCode.SWITCH, + name="Plug", + ), + ), # Cirquit Breaker "dlq": ( SwitchEntityDescription(