Преглед изворни кода

Aubess 1gang switch: ensure select has options at startup

When there is no data from the device yet, select for initial state was
evaluated as having no values.
Default to having word values, so the initialisation picks up the options.

Issue #3112
Jason Rumney пре 11 месеци
родитељ
комит
c2fd0e715b
1 измењених фајлова са 7 додато и 7 уклоњено
  1. 7 7
      custom_components/tuya_local/devices/aubess_1gang_switch.yaml

+ 7 - 7
custom_components/tuya_local/devices/aubess_1gang_switch.yaml

@@ -77,13 +77,13 @@ entities:
         type: string
         name: word_values
         mapping:
-          - dps_val: "on"
-            value: true
-          - dps_val: "off"
-            value: true
-          - dps_val: memory
-            value: true
-          - value: false
+          - dps_val: "0"
+            value: false
+          - dps_val: "1"
+            value: false
+          - dps_val: "2"
+            value: false
+          - value: true
   - entity: sensor
     name: Energy
     category: diagnostic