Ver Fonte

Add Dual smartplug with power monitoring

Tuya portal also shows the add_ele for full energy monitoring, but it is not
showng up in the debug info from the user.  Anyway, these add_ele readings
have proven to be too transient to be useful since the devices seem to clear
them back to 0 after sending the increment to the portal.

Issue #342
Jason Rumney há 3 anos atrás
pai
commit
d270da9947

+ 2 - 0
ACKNOWLEDGEMENTS.md

@@ -154,3 +154,5 @@ Further device support has been made with the assistance of users.  Please consi
 - [BrettEBowman](https://github.com/BrettEBowman) for assistance supporting Treatlife DS02-F fans.
 - [sohail579](https://github.com/sohail579) for assistance supporting Inventor Eva Ion Pro dehumidifiers.
 - [MoosJ80](https://github.com/MoosJ80) for assistance supporting PJ-1103 clamp power meters.
+- [david1111967](https://github.com/david1111967) for contributing Spanish translations.
+- [s3anyboy](https://github.com/s3anyboy) for assistance supporting Dual power monitoring smartplug (Geex).

+ 1 - 0
DEVICES.md

@@ -163,6 +163,7 @@
 - Aubess 2-gang switch
 - DIGOO DG-SP202 dual smartplug with energy monitoring and timers.
 - DIGOO DG-SP01 USB smartplug with night light.
+- Dual power monitoring smartplug (Geex).
 - ES01 3 outlet + USB powerstrip with individual timers.
 - Grid Connect double outlet wall socket
 - Grid Connect double outlet with Energy Monitoring, Master and Individual switches and Child Lock

+ 87 - 0
custom_components/tuya_local/devices/dual_power_monitor_smartplug.yaml

@@ -0,0 +1,87 @@
+name: Dual power monitoring smartplug
+primary_entity:
+  entity: switch
+  name: Outlet 1
+  class: outlet
+  dps:
+    - id: 1
+      type: boolean
+      name: switch
+    - id: 6
+      type: integer
+      name: add_ele
+      optional: true
+secondary_entities:
+  - entity: switch
+    name: Outlet 2
+    class: outlet
+    dps:
+      - id: 2
+        type: boolean
+        name: switch
+  - entity: sensor
+    name: Current
+    class: current
+    category: diagnostic
+    dps:
+      - id: 7
+        type: integer
+        name: sensor
+        unit: A
+        class: measurement
+        mapping:
+          - scale: 1000
+  - entity: sensor
+    name: Power
+    class: power
+    category: diagnostic
+    dps:
+      - id: 8
+        type: integer
+        name: sensor
+        unit: W
+        class: measurement
+        mapping:
+          - scale: 10
+  - entity: sensor
+    name: Voltage
+    class: voltage
+    category: diagnostic
+    dps:
+      - id: 9
+        type: integer
+        name: sensor
+        unit: V
+        class: measurement
+        mapping:
+          - scale: 10
+  - entity: number
+    name: Timer 1
+    category: config
+    icon: "mdi:timer"
+    dps:
+      - id: 10
+        type: integer
+        name: value
+        unit: min
+        range:
+          min: 0
+          max: 86400
+        mapping:
+          - scale: 60
+            step: 60
+  - entity: number
+    name: Timer 2
+    category: config
+    icon: "mdi:timer"
+    dps:
+      - id: 11
+        type: integer
+        name: value
+        unit: min
+        range:
+          min: 0
+          max: 86400
+        mapping:
+          - scale: 60
+            step: 60