Przeglądaj źródła

Lights: standardize scaling of brightness ranges.

Jason Rumney 2 lat temu
rodzic
commit
827a3e503e

+ 2 - 0
custom_components/tuya_local/devices/chanfok_fan_light.yaml

@@ -42,6 +42,8 @@ secondary_entities:
         range:
           min: 10
           max: 1000
+        mapping:
+          - scale: 3.92
       - id: 23
         name: color_temp
         type: integer

+ 2 - 0
custom_components/tuya_local/devices/dimming_lightbulb.yaml

@@ -16,3 +16,5 @@ primary_entity:
       range:
         min: 10
         max: 1000
+      mapping:
+        - scale: 3.92

+ 3 - 0
custom_components/tuya_local/devices/etersky_aroma_diffuser.yaml

@@ -44,6 +44,9 @@ secondary_entities:
         name: brightness
         type: integer
         optional: true
+        range:
+          min: 3
+          max: 255
       - id: 9
         name: color_mode
         type: string

+ 2 - 1
custom_components/tuya_local/devices/moes_dimmer.yaml

@@ -11,7 +11,8 @@ primary_entity:
       range:
         min: 10
         max: 1000
-
+      mapping:
+        - scale: 3.92
     - id: 13
       name: work_mode
       type: string

+ 3 - 3
custom_components/tuya_local/devices/stadlerform_eva_humidifier.yaml

@@ -96,8 +96,8 @@ secondary_entities:
         type: string
         mapping:
           - dps_val: "0x00"
-            value: 100
+            value: 255
           - dps_val: "0x01"
-            value: 50
+            value: 128
           - dps_val: "0x02"
-            value: 0
+            value: 10

+ 2 - 1
custom_components/tuya_local/devices/t5e_wf_thermostat.yaml

@@ -389,7 +389,8 @@ secondary_entities:
           min: 10
           max: 100
         mapping:
-        - step: 10
+          - step: 10
+            scale: 0.392
   - entity: binary_sensor
     name: Fault
     category: diagnostic

+ 0 - 5
custom_components/tuya_local/devices/wetair_wch750_heater.yaml

@@ -72,17 +72,12 @@ secondary_entities:
         mapping:
           - dps_val: level0
             value: 0
-            step: 85
           - dps_val: level1
             value: 85
-            step: 85
           - dps_val: level2
             value: 170
-            step: 85
           - dps_val: level3
             value: 255
-            step: 85
-          - step: 85
   - entity: select
     name: Timer
     icon: "mdi:timer"