Просмотр исходного кода

Add support for HCT-611 water timer via Bluetooth hub.

Issue #638
Jason Rumney 2 лет назад
Родитель
Сommit
5131e07af2
3 измененных файлов с 81 добавлено и 0 удалено
  1. 1 0
      ACKNOWLEDGEMENTS.md
  2. 1 0
      DEVICES.md
  3. 79 0
      custom_components/tuya_local/devices/ble_hct611_watertimer.yaml

+ 1 - 0
ACKNOWLEDGEMENTS.md

@@ -255,3 +255,4 @@ Further device support has been made with the assistance of users.  Please consi
 - [burn1879](https://github.com/burn1879) for contributing support for subdevices, and Loratap zigbee curtains.
 - [hronek](https://github.com/hronek) for assisting with support for BLE PT216 temperature and humidity sensors.
 - [bparten](https://github.com/bparten) for assisting with support for Moes IR hub connected heatpump.
+- [spanzetta](https://github.com/spanzetta) for assisting with BLE connected HCT-611 water timer.

+ 1 - 0
DEVICES.md

@@ -374,6 +374,7 @@ of device.
 ### Devices supported via Bluetooth hubs
 
 - PT216/PT19DB-2 BLE temperature and humidity sensor
+- HCT-611 water timer
 
 ### Devices supported via IR hubs
 

+ 79 - 0
custom_components/tuya_local/devices/ble_hct611_watertimer.yaml

@@ -0,0 +1,79 @@
+name: Water timer
+primary_entity:
+  entity: switch
+  dps:
+    - id: 1
+      type: boolean
+      name: switch
+    - id: 12
+      type: string
+      name: state
+secondary_entities:
+  - entity: sensor
+    name: Battery
+    class: battery
+    category: diagnostic
+    dps:
+      - id: 7
+        type: integer
+        name: sensor
+        unit: "%"
+        mapping:
+          - scale: 0.05
+      - id: 8
+        type: string
+        name: state
+  - entity: select
+    name: Weather delay
+    icon: "mdi:weather-cloudy-clock"
+    category: config
+    dps:
+      - id: 10
+        type: string
+        name: option
+        mapping:
+          - dps_val: cancel
+            value: "Off"
+          - dps_val: "24h"
+            value: "1 day"
+          - dps_val: "48h"
+            value: "2 days"
+          - dps_val: "72h"
+            value: "3 days"
+  - entity: number
+    name: Timer
+    category: config
+    icon: "mdi:timer"
+    dps:
+      - id: 11
+        type: integer
+        name: value
+        unit: min
+        range:
+          min: 0
+          max: 86400
+        mapping:
+          - scale: 60
+            step: 60
+  - entity: select
+    name: Smart weather
+    icon: "mdi:sun-wireless"
+    category: config
+    dps:
+      - id: 13
+        type: string
+        name: option
+        mapping:
+          - dps_val: sunny
+            value: Sunny
+          - dps_val: clear
+            value: Clear
+          - dps_val: cloudy
+            value: Cloudy
+          - dps_val: rainy
+            value: Rain
+          - dps_val: snow
+            value: Snow
+          - dps_val: fog
+            value: Fog
+