Przeglądaj źródła

Add support for CNC YCB9ZF circuit breaker.

Issue #1375
Jason Rumney 2 lat temu
rodzic
commit
c21dd896ab

+ 1 - 0
ACKNOWLEDGEMENTS.md

@@ -454,3 +454,4 @@ Further device support has been made with the assistance of users. Please consid
 - [kkot86](https://github.com/kkot86) for contributing support for Air Housekeeper air quality monitors.
 - [NoXPhasma](https://github.com/NoXPhasma) for assisting with support for Juskys oil radiators.
 - [lundyfpv](https://github.com/lundyfpv) for assisting with support for Touchstone Sideline electric fireplaces.
+- [tsaouste](https://github.com/tsaouste) for assisting with support for CNC YCB9ZF-100W circuit breakers.

+ 1 - 0
DEVICES.md

@@ -291,6 +291,7 @@
 - Atorch AT2PL energy monitoring breaker switch
 - Aulifants SMES200 energy monitoring breaker switch
 - CBI Astute smart controller breaker switch
+- CNC YCB9ZF-100W 1P circuit breaker
 - Compteur digital electric (single phase)
 - Dcenta dual clamp meter
 - DTS238-7 3 phase smart meter

+ 140 - 0
custom_components/tuya_local/devices/cnc_ycb9zf_breaker.yaml

@@ -0,0 +1,140 @@
+name: Circuit breaker
+# products:
+#  - id: [TBC]
+#    name: Faens FSZN03-100AP 2P
+primary_entity:
+  entity: switch
+  icon: "mdi:fuse"
+  dps:
+    - id: 1
+      type: boolean
+      name: switch
+    - id: 101
+      type: string
+      name: event
+    - id: 110
+      type: string
+      optional: true
+      name: version
+secondary_entities:
+  - entity: sensor
+    class: voltage
+    category: diagnostic
+    dps:
+      - id: 22
+        type: integer
+        name: sensor
+        unit: V
+        class: measurement
+        mapping:
+          - scale: 10
+      - id: 25
+        type: integer
+        name: calibration
+  - entity: number
+    name: Overvoltage threshold
+    category: config
+    icon: "mdi:arrow-collapse-up"
+    dps:
+      - id: 102
+        type: integer
+        name: value
+        unit: "%"
+        range:
+          min: 110
+          max: 200
+  - entity: number
+    name: Undervoltage threshold
+    category: config
+    icon: "mdi:arrow-collapse-down"
+    dps:
+      - id: 103
+        type: integer
+        name: value
+        unit: "%"
+        range:
+          min: 50
+          max: 90
+  - entity: number
+    name: Rated voltage
+    class: voltage
+    category: config
+    dps:
+      - id: 104
+        type: integer
+        name: value
+        unit: V
+        range:
+          min: 150
+          max: 300
+  - entity: select
+    name: Overvoltage action
+    category: config
+    dps:
+      - id: 105
+        type: string
+        name: option
+        mapping:
+          - dps_val: Shut
+            value: Remain closed
+            icon: "mdi:electric-switch-closed"
+          - dps_val: Alarm
+            value: Alarm
+            icon: "mdi:bell-alert"
+          - dps_val: Trip
+            value: Trip
+            icon: "mdi:electric-switch"
+  - entity: select
+    name: Undervoltage action
+    category: config
+    dps:
+      - id: 106
+        type: string
+        name: option
+        mapping:
+          - dps_val: Shut
+            value: Remain closed
+            icon: "mdi:electric-switch-closed"
+          - dps_val: Alarm
+            value: Alarm
+            icon: "mdi:bell-alert"
+          - dps_val: Trip
+            value: Trip
+            icon: "mdi:electric-switch"
+  - entity: number
+    name: Overvoltage delay
+    category: config
+    icon: "mdi:camera-timer"
+    dps:
+      - id: 107
+        type: integer
+        name: value
+        unit: s
+        range:
+          min: 100
+          max: 10000
+        mapping:
+          - step: 100
+            scale: 1000
+  - entity: number
+    name: Undervoltage delay
+    category: config
+    icon: "mdi:camera-timer"
+    dps:
+      - id: 108
+        type: integer
+        name: value
+        unit: s
+        range:
+          min: 1
+          max: 10
+  - entity: switch
+    name: Auto reset
+    category: config
+    icon: "mdi:refresh-auto"
+    dps:
+      - id: 109
+        type: boolean
+        name: switch
+
+