Explorar o código

Mirabella Genio USB: expose timer as a number entity.

As this is an older config predating number platform support, the timer was just
added as an attribute.
Jason Rumney %!s(int64=2) %!d(string=hai) anos
pai
achega
8dea3db74a
Modificáronse 1 ficheiros con 16 adicións e 3 borrados
  1. 16 3
      custom_components/tuya_local/devices/mirabella_genio_usb.yaml

+ 16 - 3
custom_components/tuya_local/devices/mirabella_genio_usb.yaml

@@ -10,6 +10,19 @@ primary_entity:
     - id: 1
       type: boolean
       name: switch
-    - id: 2
-      type: integer
-      name: timer
+secondary_entities:
+  - entity: number
+    name: Timer
+    category: config
+    icon: "mdi:timer"
+    dps:
+      - id: 2
+        type: integer
+        name: value
+        unit: min
+        range:
+          min: 0
+          max: 86400
+        mapping:
+          - scale: 60
+            step: 60