瀏覽代碼

ZTH08ZTU sensors: add battery state dp

Issue #785
Jason Rumney 2 年之前
父節點
當前提交
9e0af3508a
共有 1 個文件被更改,包括 17 次插入0 次删除
  1. 17 0
      custom_components/tuya_local/devices/zigbee_zth08ztu_temphumid_sensor.yaml

+ 17 - 0
custom_components/tuya_local/devices/zigbee_zth08ztu_temphumid_sensor.yaml

@@ -24,5 +24,22 @@ secondary_entities:
         name: sensor
         unit: "%"
         class: measurement
+  - entity: sensor
+    name: Battery
+    class: enum
+    category: diagnostic
+    dps:
+      - id: 3
+        type: integer
+        name: sensor
+        optional: true
+        mapping:
+          - dps_val: low
+            value: low
+          - dps_val: middle
+            value: medium
+          - dps_val: high
+            value: high
+