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

Add support for TOMPD-63LW circuit breaker/energy meter

Issue #388
Jason Rumney 3 лет назад
Родитель
Сommit
7b70f2ed55
3 измененных файлов с 113 добавлено и 0 удалено
  1. 1 0
      ACKNOWLEDGEMENTS.md
  2. 1 0
      DEVICES.md
  3. 111 0
      custom_components/tuya_local/devices/tompd_63lw_breaker.yaml

+ 1 - 0
ACKNOWLEDGEMENTS.md

@@ -175,3 +175,4 @@ Further device support has been made with the assistance of users.  Please consi
 - [janchrillesen](https://github.com/janchrillesen) for assistance supporting Nedis air quality monitors.
 - [Celezak](https://github.com/Celezak) for assistance supporting Qnect 3 outlet + USB powerstrips.
 - [ShayGus](https://github.com/ShayGus) for contributing support for Avatto curtain and light switch.
+- [garry0garry](https://github.com/garry0garry) for assistance supporting TOMPD circuit breakers.

+ 1 - 0
DEVICES.md

@@ -163,6 +163,7 @@
 - PJ-1103 power clamp meter
 - SG600MD Smart Solar Inverter (also SG700MD, other SGxx0MD and SGxx0W models) sold under various brands
 - SmartMCB SMT006 energy meter
+- TOMPD-63LW energy meter circuit breaker
 
 ### Battery Charger
 

+ 111 - 0
custom_components/tuya_local/devices/tompd_63lw_breaker.yaml

@@ -0,0 +1,111 @@
+name: Circuit breaker energy meter
+product:
+  - id: rrmpzckqm5pfd642
+    name: TOMPD-63LW
+primary_entity:
+  entity: switch
+  dps:
+    - id: 16
+      name: switch
+      type: boolean
+    - id: 17
+      name: alarm_set_1
+      optional: true
+      type: string
+    - id: 18
+      name: alarm_set_2
+      optional: true
+      type: string
+    - id: 6
+      name: phase_a
+      type: string
+      optional: true
+    - id: 9
+      name: fault
+      type: bitfield
+      mapping:
+        - dps_val: 0
+          value: OK
+    - id: 19
+      name: breaker_number
+      type: string
+secondary_entities:
+  - entity: switch
+    name: Prepayment
+    icon: "mdi:cash-multiple"
+    category: config
+    dps:
+      - id: 11
+        type: boolean
+        name: switch
+  - entity: button
+    name: Energy reset
+    class: restart
+    category: config
+    dps:
+      - id: 12
+        type: string
+        name: button
+        optional: true
+        mapping:
+          - dps_val: empty
+            value: true
+  - entity: sensor
+    name: Balance energy
+    class: energy
+    category: diagnostic
+    dps:
+      - id: 13
+        type: integer
+        name: sensor
+        unit: kWh
+        class: measurement
+        mapping:
+          - scale: 10
+  - entity: number
+    name: Charge energy
+    category: config
+    icon: "mdi:cash"
+    dps:
+      - id: 14
+        type: integer
+        name: value
+        optional: true
+        unit: kWh
+        range:
+          min: 0
+          max: 99999
+        mapping:
+          - scale: 10
+  - entity: sensor
+    name: Leakage current
+    class: current
+    category: diagnostic
+    dps:
+      - id: 15
+        type: integer
+        name: sensor
+        unit: mA
+        class: measurement
+  - entity: button
+    name: Earth leak test
+    icon: "mdi:current-ac"
+    category: config
+    dps:
+      - id: 21
+        type: boolean
+        name: button
+        optional: true
+  - entity: sensor
+    name: Energy
+    class: energy
+    dps:
+      - id: 1
+        type: integer
+        name: sensor
+        unit: kWh
+        class: measurement
+        mapping:
+          - scale: 100
+
+