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

fix (immax_neolite_weatherstation): match without outdoor unit

Config was originally made with the extra remote sensors optional, but the
assumption that data from the main outdoor unit is always available.
Issue #4041 seems to be missing all the outdoor sensor info, so it seems
some users will try to set up the indoor unit only first.

Changed one of the duplicate product details for immax to the matched Emax
product. It isn't clear which is the OEM, likely these are a rebadging of
the same hardware, though the previous report noting a match for this
product id may have been for Emax branded hardware too.
Jason Rumney пре 3 месеци
родитељ
комит
ce12995c05
1 измењених фајлова са 21 додато и 2 уклоњено
  1. 21 2
      custom_components/tuya_local/devices/immax_neolite_weatherstation.yaml

+ 21 - 2
custom_components/tuya_local/devices/immax_neolite_weatherstation.yaml

@@ -4,8 +4,8 @@ products:
     manufacturer: Immax
     manufacturer: Immax
     model: Neo Lite Smart professional 7-in-1
     model: Neo Lite Smart professional 7-in-1
   - id: 6cwineqz1ndjmuee
   - id: 6cwineqz1ndjmuee
-    manufacturer: Immax
-    model: Neo Lite Smart professional 7-in-1
+    manufacturer: Emax
+    model: EM3395TY-2
   - id: pj4qomlesttsisgi
   - id: pj4qomlesttsisgi
     manufacturer: Horisont
     manufacturer: Horisont
     model: Pro-5 WIFI Weather Station
     model: Pro-5 WIFI Weather Station
@@ -127,6 +127,7 @@ entities:
       - id: 38
       - id: 38
         type: integer
         type: integer
         name: sensor
         name: sensor
+        optional: true
         unit: C
         unit: C
         class: measurement
         class: measurement
         mapping:
         mapping:
@@ -136,6 +137,7 @@ entities:
     dps:
     dps:
       - id: 39
       - id: 39
         type: integer
         type: integer
+        optional: true
         name: sensor
         name: sensor
         unit: "%"
         unit: "%"
         class: measurement
         class: measurement
@@ -275,6 +277,7 @@ entities:
     dps:
     dps:
       - id: 56
       - id: 56
         type: integer
         type: integer
+        optional: true
         name: sensor
         name: sensor
         unit: km/h
         unit: km/h
         class: measurement
         class: measurement
@@ -286,6 +289,7 @@ entities:
     dps:
     dps:
       - id: 57
       - id: 57
         type: integer
         type: integer
+        optional: true
         name: sensor
         name: sensor
         unit: km/h
         unit: km/h
         class: measurement
         class: measurement
@@ -296,6 +300,7 @@ entities:
     dps:
     dps:
       - id: 60
       - id: 60
         type: integer
         type: integer
+        optional: true
         name: sensor
         name: sensor
         unit: mm
         unit: mm
         class: measurement
         class: measurement
@@ -303,6 +308,7 @@ entities:
           - scale: 10
           - scale: 10
       - id: 59
       - id: 59
         type: integer
         type: integer
+        optional: true
         name: hourly
         name: hourly
         mapping:
         mapping:
           - scale: 10
           - scale: 10
@@ -311,6 +317,7 @@ entities:
     dps:
     dps:
       - id: 61
       - id: 61
         type: integer
         type: integer
+        optional: true
         name: sensor
         name: sensor
         unit: mm/h
         unit: mm/h
         class: measurement
         class: measurement
@@ -322,6 +329,7 @@ entities:
     dps:
     dps:
       - id: 62
       - id: 62
         type: integer
         type: integer
+        optional: true
         name: sensor
         name: sensor
         class: measurement
         class: measurement
   - entity: sensor
   - entity: sensor
@@ -330,6 +338,7 @@ entities:
     dps:
     dps:
       - id: 64
       - id: 64
         type: integer
         type: integer
+        optional: true
         name: sensor
         name: sensor
         unit: C
         unit: C
         class: measurement
         class: measurement
@@ -341,6 +350,7 @@ entities:
     dps:
     dps:
       - id: 65
       - id: 65
         type: integer
         type: integer
+        optional: true
         name: sensor
         name: sensor
         unit: C
         unit: C
         class: measurement
         class: measurement
@@ -352,6 +362,7 @@ entities:
     dps:
     dps:
       - id: 66
       - id: 66
         type: integer
         type: integer
+        optional: true
         name: sensor
         name: sensor
         unit: C
         unit: C
         class: measurement
         class: measurement
@@ -436,11 +447,13 @@ entities:
     dps:
     dps:
       - id: 113
       - id: 113
         type: base64
         type: base64
+        optional: true
         mask: "00FF000000000000000000000000000000000000000000000000000000000000"
         mask: "00FF000000000000000000000000000000000000000000000000000000000000"
         unit: "%"
         unit: "%"
         name: sensor
         name: sensor
       - id: 113
       - id: 113
         type: base64
         type: base64
+        optional: true
         name: raw_data
         name: raw_data
   - entity: text
   - entity: text
     name: Backlight
     name: Backlight
@@ -467,6 +480,7 @@ entities:
     dps:
     dps:
       - id: 127
       - id: 127
         type: integer
         type: integer
+        optional: true
         name: sensor
         name: sensor
         unit: mm
         unit: mm
         class: measurement
         class: measurement
@@ -478,6 +492,7 @@ entities:
     dps:
     dps:
       - id: 131
       - id: 131
         type: integer
         type: integer
+        optional: true
         name: sensor
         name: sensor
         unit: km/h
         unit: km/h
         class: measurement
         class: measurement
@@ -488,17 +503,20 @@ entities:
     dps:
     dps:
       - id: 134
       - id: 134
         type: base64
         type: base64
+        optional: true
         name: sensor
         name: sensor
         mask: "0000000000FFFF0000"
         mask: "0000000000FFFF0000"
         unit: °
         unit: °
       - id: 134
       - id: 134
         type: base64
         type: base64
+        optional: true
         name: raw_data
         name: raw_data
   - entity: sensor
   - entity: sensor
     class: illuminance
     class: illuminance
     dps:
     dps:
       - id: 135
       - id: 135
         type: integer
         type: integer
+        optional: true
         name: sensor
         name: sensor
         unit: lx
         unit: lx
         class: measurement
         class: measurement
@@ -510,6 +528,7 @@ entities:
     dps:
     dps:
       - id: 137
       - id: 137
         type: integer
         type: integer
+        optional: true
         name: sensor
         name: sensor
         unit: min
         unit: min
         class: measurement
         class: measurement