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

feat: Remove the distinction between primary and secondary entities for airx h8 humidifier

李余通 1 год назад
Родитель
Сommit
e8c1762a86
1 измененных файлов с 35 добавлено и 36 удалено
  1. 35 36
      custom_components/tuya_local/devices/airx_h8_humidifier.yaml

+ 35 - 36
custom_components/tuya_local/devices/airx_h8_humidifier.yaml

@@ -2,42 +2,41 @@ name: Humidifier
 products:
   - id: orypuo7ksduqze3x
     name: airx纯净加湿器H8Pro
-primary_entity:
-  entity: humidifier
-  class: humidifier
-  dps:
-    - id: 1
-      name: switch
-      type: boolean
-      mapping:
-        - dps_val: true
-          icon: "mdi:air-humidifier"
-        - dps_val: false
-          icon: "mdi:air-humidifier-off"
-    - id: 13
-      name: humidity
-      type: integer
-      range:
-        min: 30
-        max: 80
-    - id: 14
-      name: current_humidity
-      type: integer
-    - id: 24
-      type: string
-      name: mode
-      mapping:
-        - dps_val: AUTO
-          value: auto
-        - dps_val: LOW
-          value: eco
-        - dps_val: MIDDLE
-          value: normal
-        - dps_val: HIGH
-          value: boost
-        - dps_val: SLEEP
-          value: sleep
-secondary_entities:
+entities:
+  - entity: humidifier
+    class: humidifier
+    dps:
+      - id: 1
+        name: switch
+        type: boolean
+        mapping:
+          - dps_val: true
+            icon: "mdi:air-humidifier"
+          - dps_val: false
+            icon: "mdi:air-humidifier-off"
+      - id: 13
+        name: humidity
+        type: integer
+        range:
+          min: 30
+          max: 80
+      - id: 14
+        name: current_humidity
+        type: integer
+      - id: 24
+        type: string
+        name: mode
+        mapping:
+          - dps_val: AUTO
+            value: auto
+          - dps_val: LOW
+            value: eco
+          - dps_val: MIDDLE
+            value: normal
+          - dps_val: HIGH
+            value: boost
+          - dps_val: SLEEP
+            value: sleep
   - entity: binary_sensor
     category: diagnostic
     translation_key: machine_separation_status