Przeglądaj źródła

Inkbird ITC-306A redirect current temperature when in F

Issue #19
When unit is set to F, the current temperature was still being returned in C,
leading to confusion in the UI.  Redirect to the current_temperature_f dp when
the unit is F, to have the expected temperature returned.
Jason Rumney 4 lat temu
rodzic
commit
3d54096e89

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

@@ -32,6 +32,10 @@ primary_entity:
       name: current_temperature
       mapping:
         - scale: 10
+        - constraint: temperature_unit
+          conditions:
+            - dps_val: F
+              value_redirect: current_temperature_f
     - id: 106
       type: integer
       name: target_temp_low
@@ -111,6 +115,7 @@ primary_entity:
       name: current_temperature_f
       mapping:
         - scale: 10
+      hidden: true
     - id: 117
       type: boolean
       name: unknown_117