Răsfoiți Sursa

Add support for Moes motion sensor lights.

Issue #579
Jason Rumney 2 ani în urmă
părinte
comite
c2cfc62a3e

+ 1 - 0
ACKNOWLEDGEMENTS.md

@@ -235,3 +235,4 @@ Further device support has been made with the assistance of users.  Please consi
 - [erelke](https://github.com/erelke) for contributing Hungarian translations.
 - [p-owerscripter](https://github.com/p-owerscripter) for contributing support for KKMoon air quality monitors.
 - [cataseven](https://github.com/cataseven) for contributing support for SM07-8 sprinkler controllers.
+- [tientmit88](https://github.com/tientmit88) for contributing support for Moes motion sensor lights.

+ 1 - 0
DEVICES.md

@@ -281,6 +281,7 @@ of device.
 - HDMI sync light
 - iHD001 LED controller
 - Moes dimmer switch
+- Moes motion sensor lights (XZ-CGV3)
 - Space Dog Music Lamp
 
 ### Covers

+ 65 - 0
custom_components/tuya_local/devices/moes_motionsensor_light.yaml

@@ -0,0 +1,65 @@
+name: Motion sensor light
+products:
+  - id: vwqnz1sn
+    name: Moes XZ-CGV3
+primary_entity:
+  entity: binary_sensor
+  name: Motion detected
+  class: motion
+  dps:
+    - id: 1
+      type: string
+      name: sensor
+      mapping:
+        - dps_val: none
+          value: false
+        - dps_val: pir
+          value: true
+secondary_entities:
+  - entity: sensor
+    name: Current luminance
+    class: illuminance
+    dps:
+      - id: 6
+        type: integer
+        name: sensor
+        unit: lx
+        class: measurement
+  - entity: sensor
+    name: Battery Level
+    class: battery
+    dps:
+      - id: 4
+        type: integer
+        name: sensor
+        unit: "%"
+  - entity: select
+    name: Sensitivity
+    icon: "mdi:human-greeting-proximity"
+    category: config
+    dps:
+      - id: 9
+        name: option
+        type: string
+        mapping:
+          - dps_val: "low"
+            value: "Low"
+          - dps_val: "middle"
+            value: "Medium"
+          - dps_val: "high"
+            value: "High"
+  - entity: select
+    name: Keep time
+    icon: "mdi:camera-timer"
+    category: config
+    dps:
+      - id: 10
+        name: option
+        type: string
+        mapping:
+          - dps_val: "30s"
+            value: "30"
+          - dps_val: "60s"
+            value: "60"
+          - dps_val: "120s"
+            value: "120"