فهرست منبع

Fixes after review.

Yurii 11 ماه پیش
والد
کامیت
2a7e410379
1فایلهای تغییر یافته به همراه14 افزوده شده و 7 حذف شده
  1. 14 7
      custom_components/tuya_local/devices/feyree_ev_portable_charger.yaml

+ 14 - 7
custom_components/tuya_local/devices/feyree_ev_portable_charger.yaml

@@ -73,14 +73,21 @@ entities:
           max: 999999
           max: 999999
         mapping:
         mapping:
           - scale: 2
           - scale: 2
-  - entity: sensor
+  - entity: binary_sensor
     name: Alarm event
     name: Alarm event
+    device_class: problem
     icon: 'mdi:alert-outline'
     icon: 'mdi:alert-outline'
-    class: enum
     dps:
     dps:
       - id: 10
       - id: 10
         type: bitfield
         type: bitfield
         name: sensor
         name: sensor
+        mapping:
+          - dps_val: 0
+            value: false
+          - value: true
+      - id: 10
+        type: bitfield
+        name: alarm_descriptions
         mapping:
         mapping:
           - dps_val: 0
           - dps_val: 0
             value: "Ready"
             value: "Ready"
@@ -93,7 +100,7 @@ entities:
           - dps_val: 8
           - dps_val: 8
             value: "Protective earth error"
             value: "Protective earth error"
           - dps_val: 16
           - dps_val: 16
-            value: "Temperature is to high"
+            value: "Temperature is too high"
           - dps_val: 32
           - dps_val: 32
             value: "Control pilot line error"
             value: "Control pilot line error"
           - dps_val: 64
           - dps_val: 64
@@ -103,11 +110,11 @@ entities:
           - dps_val: 256
           - dps_val: 256
             value: "Protective earth error 2"
             value: "Protective earth error 2"
           - dps_val: 512
           - dps_val: 512
-            value: "Plug temperature is to high."
+            value: "Plug temperature is too high"
           - dps_val: 1024
           - dps_val: 1024
-            value: "PCB temperature is to high."
+            value: "PCB temperature is too high"
           - dps_val: 2048
           - dps_val: 2048
-            value: "Core temperature is to high."
+            value: "Core temperature is too high"
           - dps_val: 4096
           - dps_val: 4096
             value: "ESB"
             value: "ESB"
           - dps_val: 8192
           - dps_val: 8192
@@ -115,7 +122,7 @@ entities:
           - dps_val: 16384
           - dps_val: 16384
             value: "Socket leakage"
             value: "Socket leakage"
           - dps_val: 32768
           - dps_val: 32768
-            value: "Socket temperature is to high."
+            value: "Socket temperature is too high"
   - entity: button
   - entity: button
     name: Clear energy
     name: Clear energy
     class: restart
     class: restart