Просмотр исходного кода

feat(devices): add Lumary D1 6" retrofit downlight (independent RGB ring + CCT) (#5612)

* feat(devices): add Lumary D1 6 inch retrofit downlight

Two independently controlled light entities (white CCT centre and
RGBAI colour ring). The ring/centre switches use DPs 54/63, which are
absent from the Tuya cloud data model (it exposes only the standard
single-channel RGBCW DPs 20-28, 34) and were found by local polling.
Verified on 6 units, both channels driven independently.

* Remove brightness setting from lumary_d1_downlight

Removed brightness dp for RGB light, it is already covered by the v in hsv.

---------

Co-authored-by: Jason Rumney <make-all@users.noreply.github.com>
jmlankford 3 дней назад
Родитель
Сommit
e9ab89af4d
2 измененных файлов с 65 добавлено и 0 удалено
  1. 1 0
      DEVICES.md
  2. 64 0
      custom_components/tuya_local/devices/lumary_d1_downlight.yaml

+ 1 - 0
DEVICES.md

@@ -960,6 +960,7 @@ of device.
 - LSC Smart Connect Neon LED strip
 - LSC Smart Connect Neon LED strip
 - LSC Smart Connect Party string lights
 - LSC Smart Connect Party string lights
 - LSC smart connect RGB CCT lightbulb (similar to older generic bulbs, so may work for others)
 - LSC smart connect RGB CCT lightbulb (similar to older generic bulbs, so may work for others)
+- Lumary D1 6 inch retrofit downlight (independent RGB ring and CCT centre)
 - Lytmi Fantasy/Neo 3 HDMI sync backlight
 - Lytmi Fantasy/Neo 3 HDMI sync backlight
 - Malmbergs QS-WIFI-D02-TRIAC single dimmer module
 - Malmbergs QS-WIFI-D02-TRIAC single dimmer module
 - Malmbergs QS-WIFI-D02-TRIAC-2C dual dimmer module
 - Malmbergs QS-WIFI-D02-TRIAC-2C dual dimmer module

+ 64 - 0
custom_components/tuya_local/devices/lumary_d1_downlight.yaml

@@ -0,0 +1,64 @@
+name: Recessed downlight
+products:
+  - id: nko0qtqcv4dsddvh
+    manufacturer: Lumary
+    model: D1
+    model_id: L-DL6D1
+  - id: key5q5hf8heh9xag
+    manufacturer: Lumary
+    model: D1
+    model_id: L-DL6D1
+entities:
+  # White CCT centre (independent switch, brightness and colour temperature)
+  - entity: light
+    name: Centre
+    icon: "mdi:circle-slice-8"
+    dps:
+      - id: 63
+        type: boolean
+        name: switch
+      - id: 22
+        name: brightness
+        type: integer
+        range:
+          min: 10
+          max: 1000
+      - id: 23
+        name: color_temp
+        type: integer
+        optional: true
+        range:
+          min: 0
+          max: 1000
+        mapping:
+          - target_range:
+              min: 2700
+              max: 6500
+  # RGB ring (independent switch, HSV colour, brightness on value channel)
+  - entity: light
+    name: Ring
+    icon: "mdi:circle-outline"
+    dps:
+      - id: 54
+        type: boolean
+        name: switch
+      - id: 24
+        name: rgbhsv
+        type: hex
+        optional: true
+        format:
+          - name: h
+            bytes: 2
+            range:
+              min: 0
+              max: 360
+          - name: s
+            bytes: 2
+            range:
+              min: 0
+              max: 1000
+          - name: v
+            bytes: 2
+            range:
+              min: 0
+              max: 1000