Explorar el Código

Add support for Minoston 6 preset timer switch

Issue #2013
Jason Rumney hace 1 año
padre
commit
4fa36890fd

+ 1 - 0
ACKNOWLEDGEMENTS.md

@@ -612,3 +612,4 @@ Further device support has been made with the assistance of users. Please consid
 - [sveos](https://github.com/sveos) for assisting with support for Nedis ZBRC10WT remote contol.
 - [RoadkillUK](https://github.com/RoadkillUK) for contributing support for Els Pet Spaceship litter box.
 - [dphuk](https://github.com/dphuk) for assisting with ElectriQ DESD8LW V2 dehumidifier.
+- [tk627](https://github.com/tk627) for assisting with Minoston 6-preset timer switch.

+ 1 - 0
DEVICES.md

@@ -430,6 +430,7 @@ the best option.
 - Loratap RR400W-V2 relay switch
 - Makegood double power point (sold under AusElectronicsDirect, Cleverlife, Kogan, Ozsmartthings and other brands)
 - MakeGood double switch with timers and power monitoring on whole device
+- Minoston 6 preset timer switch
 - Mirabella Genio smartplug with USB
 - Moes 3-gang switch
 - Moes 4-gang (quad) switch

+ 159 - 0
custom_components/tuya_local/devices/minoston_timer_switch.yaml

@@ -0,0 +1,159 @@
+name: Timer switch
+products:
+  - id: ae0y7quogjcnzery
+    name: Minoston nhT06-WIFI
+primary_entity:
+  entity: switch
+  dps:
+    - id: 1
+      type: boolean
+      name: switch
+secondary_entities:
+  - entity: number
+    translation_key: timer
+    category: config
+    dps:
+      - id: 7
+        type: integer
+        name: value
+        unit: s
+        range:
+          min: 0
+          max: 86400
+  - entity: number
+    name: Preset 1 time
+    translation_key: timer
+    category: config
+    dps:
+      - id: 101
+        type: integer
+        name: value
+        unit: s
+        range:
+          min: 0
+          max: 86400
+  - entity: number
+    name: Preset 2 time
+    translation_key: timer
+    category: config
+    dps:
+      - id: 102
+        type: integer
+        name: value
+        unit: s
+        range:
+          min: 0
+          max: 86400
+  - entity: number
+    name: Preset 3 time
+    translation_key: timer
+    category: config
+    dps:
+      - id: 103
+        type: integer
+        name: value
+        unit: s
+        range:
+          min: 0
+          max: 86400
+  - entity: number
+    name: Preset 4 time
+    translation_key: timer
+    category: config
+    dps:
+      - id: 104
+        type: integer
+        name: value
+        unit: s
+        range:
+          min: 0
+          max: 86400
+  - entity: number
+    name: Preset 5 time
+    translation_key: timer
+    category: config
+    dps:
+      - id: 105
+        type: integer
+        name: value
+        unit: s
+        range:
+          min: 0
+          max: 86400
+  - entity: number
+    name: Preset 6 time
+    translation_key: timer
+    category: config
+    dps:
+      - id: 106
+        type: integer
+        name: value
+        unit: s
+        range:
+          min: 0
+          max: 86400
+  - entity: light
+    translation_key: indicator
+    category: config
+    dps:
+      - id: 107
+        name: brightness
+        type: integer
+        range:
+          min: 0
+          max: 100
+  - entity: sensor
+    name: Active timer
+    class: enum
+    category: diagnostic
+    dps:
+      - id: 108
+        type: integer
+        name: sensor
+        mapping:
+          - dps_val: 0
+            value: None
+          - dps_val: 1
+            value: Preset 1
+          - dps_val: 2
+            value: Preset 2
+          - dps_val: 3
+            value: Preset 3
+          - dps_val: 4
+            value: Preset 4
+          - dps_val: 5
+            value: Preset 5
+          - dps_val: 6
+            value: Preset 6
+  - entity: select
+    name: Power indicator
+    icon: "mdi:led-on"
+    category: config
+    dps:
+      - id: 109
+        type: string
+        name: option
+        mapping:
+          - dps_val: "on"
+            value: Solid
+          - dps_val: flicker
+            value: Blink
+  - entity: select
+    name: Timer indicator
+    icon: "mdi:led-on"
+    category: config
+    dps:
+      - id: 110
+        type: string
+        name: option
+        mapping:
+          - dps_val: "on"
+            value: Solid
+          - dps_val: flicker
+            value: Blink
+  - entity: switch
+    name: Override
+    dps:
+      - id: 111
+        type: boolean
+        name: switch