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

loratap curtain: use the modern mapping when value is null

The cover is being set up before values are fetched, so we cannot determine the actual
mappings yet.  Returning an empty list of values is not working, so in this case return
the most common one.  Later when we have values the correct mapping will become available.

Issue #704
Jason Rumney 2 лет назад
Родитель
Сommit
4de3b0d073
1 измененных файлов с 1 добавлено и 1 удалено
  1. 1 1
      custom_components/tuya_local/devices/loratap_curtain_switch.yaml

+ 1 - 1
custom_components/tuya_local/devices/loratap_curtain_switch.yaml

@@ -21,7 +21,7 @@ primary_entity:
                   value: close
                 - dps_val: "3"
                   value: stop
-            - dps_val: [ "open", "close", "stop", "continue" ]
+            - dps_val: [ "open", "close", "stop", "continue", null ]
               mapping:
                 - dps_val: open
                   value: open