4
0
Эх сурвалжийг харах

Added support for Carro PN-04F02D Fan/Light Switch

JonF-49 2 жил өмнө
parent
commit
50999183a3

+ 45 - 0
custom_components/tuya_local/devices/carro_pn04f02d_fan_light.yaml

@@ -0,0 +1,45 @@
+name: Ceiling Fan and Light Switch
+product:
+  - id: 6ahfblexspuaem65
+    name: Carro PN-04F02D ceiling fan and light switch
+primary_entity:
+  entity: light
+  dps:
+    - id: 20
+      type: boolean
+      name: switch
+    - id: 21
+      type: string
+      # Shows in the instruction set with standard white/colour/scene/music properties
+      # but this is a dimming switch and doesn't have color/scene dps
+      name: work_mode
+      optional: true
+    - id: 22
+      name: brightness
+      type: integer
+      range:
+        min: 10
+        max: 1000
+      mapping:
+        - scale: 3.92
+    - id: 28
+      type: string
+      name: control_data
+      optional: true
+secondary_entities:
+  - entity: fan
+    dps:
+      - id: 60
+        type: boolean
+        name: switch
+      - id: 62
+        type: integer 
+        name: speed
+        mapping:
+          - dps_val: 1
+            value: 33 
+          - dps_val: 2
+            value: 66 
+          - dps_val: 3
+            value: 100 
+