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

BEOK TOL47: simplify hvac_mode, add hvac_action.

Use work_state for hvac_action rather than trying to complicate hvac_mode.
Use the switch directly for hvac_mode without any other attribute.
Add max_temperature into climate entity so it affects the UI too.
Jason Rumney 3 лет назад
Родитель
Сommit
d02ec17daf
1 измененных файлов с 14 добавлено и 8 удалено
  1. 14 8
      custom_components/tuya_local/devices/beok_tol47_thermostat.yaml

+ 14 - 8
custom_components/tuya_local/devices/beok_tol47_thermostat.yaml

@@ -4,17 +4,21 @@ primary_entity:
   dps:
     - id: 1
       type: boolean
-      name: power
+      name: hvac_mode
       mapping:
         - dps_val: false
           value: "off"
-      hidden: true
+        - dps_val: true
+          value: heat
     - id: 2
       type: integer
       name: temperature
       mapping:
         - scale: 10
           step: 5
+      range:
+        min: 50
+        max: 950
     - id: 3
       type: integer
       name: current_temperature
@@ -32,23 +36,25 @@ primary_entity:
           value: Temporary program mode
     - id: 5
       type: string
-      name: hvac_mode
+      name: hvac_action
       mapping:
         - dps_val: "0"
           constraint: power
           conditions:
             - dps_val: true
-              value: auto
+              value: idle
             - dps_val: false
-              value_redirect: power
               value: "off"
         - dps_val: "1"
           constraint: power
           conditions:
             - dps_val: true
-              value: heat
+              value: heating
             - dps_val: false
-              value_redirect: power
+              value: "off"
+    - id: 21
+      type: integer
+      name: max_temperature
 secondary_entities:
   - entity: lock
     name: Child lock
@@ -201,4 +207,4 @@ secondary_entities:
         unit: C
         range:
           min: 5
-          max: 60
+          max: 60