فهرست منبع

Della airconditioner: review fixes

- simplify temperature conditions, ensure there is a range to fall back on
- remove duplicated aux_heat control
- move fault code to extra attribute on climate entity, and change the sensor to binary_sensor that just indicates that a fault exists.
Jason Rumney 2 سال پیش
والد
کامیت
783b39cbd3
1فایلهای تغییر یافته به همراه18 افزوده شده و 20 حذف شده
  1. 18 20
      custom_components/tuya_local/devices/della_airconditioner.yaml

+ 18 - 20
custom_components/tuya_local/devices/della_airconditioner.yaml

@@ -20,22 +20,19 @@ primary_entity:
             - dps_val: wind
               value: fan_only
             - dps_val: auto
-              value: auto
+              value: heat_cool
     - id: 2
       name: temperature
       type: integer
+      range:
+        min: 160
+        max: 320
       mapping:
-        - constraint: temperature_unit
+        - scale: 10
+          step: 10
+          constraint: temperature_unit
           conditions:
-            - dps_val: C
-              scale: 10
-              step: 10
-              range:
-                min: 160
-                max: 320
             - dps_val: F
-              scale: 10
-              step: 10
               range:
                 min: 600
                 max: 900
@@ -83,14 +80,10 @@ primary_entity:
           value: vertical
         - dps_val: false
           value: "off"
-
+    - id: 107
+      type: bitfield
+      name: fault_code
 secondary_entities:
-  - entity: switch
-    name: Aux heat
-    dps:
-      - id: 12
-        name: switch
-        type: boolean
   - entity: light
     name: Backlight
     category: config
@@ -157,10 +150,15 @@ secondary_entities:
       - id: 106
         name: switch
         type: boolean
-  - entity: sensor
-    name: Fault code
+  - entity: binary_sensor
+    name: Fault
+    class: problem
     category: diagnostic
     dps:
       - id: 107
         name: sensor
-        type: integer
+        type: bitfield
+        mapping:
+          - dps_val: 0
+            value: false
+          - value: true