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

feat(moebot_s_mower): add compatibility with Bluetooth Parkside variants

- battery sensor is on dp 13 instead of 6
- there are other dps listed that appear to be vacuum status and
  commands, but they do not appear in the logs, so assume they are mistakes

Issue #4859
Jason Rumney 1 месяц назад
Родитель
Сommit
50f4961d19
1 измененных файлов с 14 добавлено и 1 удалено
  1. 14 1
      custom_components/tuya_local/devices/moebot_s_mower.yaml

+ 14 - 1
custom_components/tuya_local/devices/moebot_s_mower.yaml

@@ -6,6 +6,9 @@ products:
   - id: icw5sal7xfcevsve
   - id: icw5sal7xfcevsve
     manufacturer: Parkside
     manufacturer: Parkside
     model: PMRDA 20-Li A1
     model: PMRDA 20-Li A1
+  - id: 7yr5iwga
+    manufacturer: Parkside
+    model: PMRC 250 Ai Bluetooth
 entities:
 entities:
   - entity: lawn_mower
   - entity: lawn_mower
     dps:
     dps:
@@ -114,9 +117,17 @@ entities:
     dps:
     dps:
       - id: 6
       - id: 6
         type: integer
         type: integer
+        optional: true
         name: sensor
         name: sensor
         unit: "%"
         unit: "%"
         class: measurement
         class: measurement
+        mapping:
+          - dps_val: null
+            value_redirect: alt
+      - id: 13
+        type: integer
+        optional: true
+        name: alt
   - entity: binary_sensor
   - entity: binary_sensor
     class: problem
     class: problem
     category: diagnostic
     category: diagnostic
@@ -305,8 +316,10 @@ entities:
     dps:
     dps:
       - id: 114
       - id: 114
         type: string
         type: string
-        name: option
+        # Parkside mowers mark this as boolean01Reserved, but as long as they don't use it
+        # the incompatibility is just theoretical
         optional: true
         optional: true
+        name: option
         mapping:
         mapping:
           - dps_val: AutoMode
           - dps_val: AutoMode
             value: Auto
             value: Auto