فهرست منبع

Peteme lighting: merge into generic Zigbee smart bulb config.

Generic Zigbee config covers the same dps and has Scene presets
defined.
Jason Rumney 1 سال پیش
والد
کامیت
57976caaf2

+ 0 - 71
custom_components/tuya_local/devices/peteme_smart_recessed_lighting.yaml

@@ -1,71 +0,0 @@
-name: RGBCW light
-products:
-  - id: sjaun9de
-    name: Peteme SIG_DL_RGBCW recessed lighting
-primary_entity:
-  entity: light
-  dps:
-    - id: 1
-      type: boolean
-      name: switch
-    - id: 2
-      name: color_mode
-      type: string
-      optional: true
-      mapping:
-        - dps_val: white
-          value: color_temp
-        - dps_val: colour
-          value: hs
-        - dps_val: scene
-          value: Scene
-        - dps_val: music
-          value: Music
-        - dps_val: null
-          value: color_temp
-    - id: 3
-      name: brightness
-      type: integer
-      optional: true
-      range:
-        min: 10
-        max: 1000
-    - id: 4
-      name: color_temp
-      type: integer
-      optional: true
-      range:
-        min: 0
-        max: 1000
-      mapping:
-        - target_range:
-            min: 2700
-            max: 6500
-    - id: 5
-      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
-    - id: 6
-      name: scene_data
-      type: hex
-      optional: true
-    - id: 8
-      name: music_data
-      type: hex
-      optional: true

+ 21 - 14
custom_components/tuya_local/devices/zigbee_smart_bulb.yaml

@@ -1,4 +1,5 @@
 name: Zigbee light
+legacy_type: peteme_smart_recessed_lighting
 products:
   - id: mja6r5ix
     name: MOES zigbee lightbulb
@@ -6,18 +7,36 @@ products:
     name: MOES zigbee RGBCW
   - id: rcggc0ys
     name: MOES ZC-TD SW zigbee GU10
+  - id: sjaun9de
+    name: Peteme SIG_DL_RGBCW recessed lighting
 primary_entity:
   entity: light
   dps:
     - id: 1
       type: boolean
       name: switch
+    - id: 2
+      name: color_mode
+      type: string
+      optional: true
+      mapping:
+        - dps_val: white
+          value: color_temp
+        - dps_val: colour
+          value: hs
+        - dps_val: scene
+          value: scene
+        - dps_val: music
+          value: music
+        - dps_val: null
+          value: color_temp
+          hidden: true
     - id: 3
       name: brightness
       type: integer
       optional: true
       range:
-        min: 0
+        min: 10
         max: 1000
     - id: 4
       name: color_temp
@@ -30,22 +49,10 @@ primary_entity:
         - target_range:
             min: 2700
             max: 6500
-    - id: 2
-      name: color_mode
-      type: string
-      optional: true
-      mapping:
-        - dps_val: white
-          value: color_temp
-        - dps_val: colour
-          value: hs
-        - dps_val: scene
-          value: scene
-        - dps_val: music
-          value: music
     - id: 5
       name: rgbhsv
       type: hex
+      optional: true
       format:
         - name: h
           bytes: 2