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

Add support for M515 curtain motor

Issue #1306
Jason Rumney 2 жил өмнө
parent
commit
b4ed502887

+ 1 - 1
ACKNOWLEDGEMENTS.md

@@ -432,6 +432,6 @@ Further device support has been made with the assistance of users. Please consid
 - [magomao](https://github.com/magomao) for assisting with support for Vivion air conditioners.
 - [palkoarpad85](https://github.com/palkoarpad85) for assisting with support for Klarstein Wonderwall heaters.
 - [MJW911](https://github.com/MJW911) for assisting with support for SX1 smartplugs.
-- [ops244](https://github.com/ops244) for assisting with support for Hiper T3 bladeless fans, TTEC Robi Pro vacuums.
+- [ops244](https://github.com/ops244) for assisting with support for Hiper T3 bladeless fans, TTEC Robi Pro vacuums, M515 curtain motors.
 - [sevimuelli](https://github.com/sevimuelli) for contributing support for Eeese Anna dehumidifiers.
 - [tataihono](https://github.com/tataihono) for contributing support for Arlec Portable Air Conditioner.

+ 1 - 0
DEVICES.md

@@ -450,6 +450,7 @@ of device.
 - LoraTap QCSC420W double curtain switch
 - LoraTap SC500W-V1 curtain switch (supports many other simple curtain/blind controllers)
 - M027 curtain module (sold under several brands, including zemismart, meterk and others)
+- M515 curtain motor
 - Moes SCS80 Touch curtain swich with backlight and timing control
 - QS-WIFI-C01(BK) curtain module
 - SHerko curtain motor

+ 99 - 0
custom_components/tuya_local/devices/m515_curtain_motor.yaml

@@ -0,0 +1,99 @@
+name: Curtain motor
+products:
+  - id: t6ief6k56sapz1ey
+    name: M515EGWT v2
+primary_entity:
+  entity: cover
+  class: curtain
+  dps:
+    - id: 1
+      name: control
+      type: string
+      mapping:
+        - dps_val: open
+          value: open
+        - dps_val: stop
+          value: stop
+        - dps_val: close
+          value: close
+    - id: 2
+      name: position
+      type: integer
+      range:
+        min: 0
+        max: 100
+    - id: 7
+      name: action
+      type: string
+      persist: false
+      optional: true
+      mapping:
+        - dps_val: opening
+          value: opening
+        - dps_val: closing
+          value: closing
+    - id: 12
+      name: fault_code
+      type: bitfield
+      optional: true
+secondary_entities:
+  - entity: switch
+    name: Reversed
+    icon: "mdi:arrow-u-left-bottom"
+    category: config
+    dps:
+      - id: 5
+        type: boolean
+        name: switch
+        optional: true
+        mapping:
+          - dps_val: null
+            value: false
+            hidden: true
+  - entity: binary_sensor
+    name: Fault
+    class: problem
+    category: diagnostic
+    dps:
+      - id: 12
+        type: bitfield
+        name: sensor
+        optional: true
+        mapping:
+          - dps_val: 0
+            value: false
+          - dps_val: null
+            value: false
+          - value: true
+  - entity: select
+    name: Border setting
+    icon: "mdi:border-bottom-variant"
+    category: config
+    dps:
+      - id: 16
+        type: string
+        name: option
+        mapping:
+          - dps_val: up
+            value: Top
+          - dps_val: down
+            value: Bottom
+          - dps_val: up_delete
+            value: Clear top
+          - dps_val: down_delete
+            value: Clear bottom
+          - dps_val: remove_top_bottom
+            value: Clear all
+  - entity: number
+    name: Best position
+    category: config
+    icon: "mdi:roller-shade"
+    dps:
+      - id: 19
+        type: integer
+        name: value
+        optional: true
+        unit: "%"
+        range:
+          min: 0
+          max: 100