Selaa lähdekoodia

Add support for BBCoin AC5299 PCIe switch

Issue #3088
Jason Rumney 9 kuukautta sitten
vanhempi
commit
a22d2725d0

+ 1 - 0
ACKNOWLEDGEMENTS.md

@@ -917,3 +917,4 @@ Further device support has been made with the assistance of users. Please consid
 - [peng1can](https://github.com/peng1can) for contributing support for Sefaul Q9 dehumidifier.
 - [fernac03](https://github.com/fernac03) for assisting with support for Primebras Athenas BLE lock.
 - [drak202](https://github.com/drak202) for assisting with support for 4-TH quad temperature/humidity switch.
+- [duckati](https://github.com/duckati) for assisting with support for BBCoin AT5299 PCIe computer switch.

+ 1 - 0
DEVICES.md

@@ -502,6 +502,7 @@ the best option.
 - Aubess 1-gang switch with energy monitoring
 - Aubess 2-gang switch
 - Bauhn APSW-0624 5 way powerstrip (with unswitched USB)
+- BBCoin AC5299 PCIe computer switch
 - Blitzwolf BW-SHP6 PRO smartplug with child lock
 - Blitzwolf BW-SHP-9 3 outlet + USB powerstrip
 - Brilliant 1/2/3/4 gang wall switches with power monitoring

+ 102 - 0
custom_components/tuya_local/devices/btbcoin_ac5299_pccontroller.yaml

@@ -0,0 +1,102 @@
+name: PCIe controller
+products:
+  - id: ycsoojvkvwipbubo
+    manufacturer: BTBcoin
+    model: AC5299
+entities:
+  - entity: switch
+    icon: "mdi:power"
+    dps:
+      - id: 1
+        type: boolean
+        name: switch
+  - entity: button
+    name: Force shutdown
+    icon: "mdi:power-off"
+    category: config
+    dps:
+      - id: 101
+        type: boolean
+        name: button
+  - entity: switch
+    name: Auto power-on
+    icon: "mdi:refresh-auto"
+    category: config
+    dps:
+      - id: 102
+        type: boolean
+        name: switch
+  - entity: lock
+    translation_key: child_lock
+    category: config
+    dps:
+      - id: 103
+        type: boolean
+        name: lock
+  - entity: button
+    name: Reset
+    class: restart
+    category: config
+    dps:
+      - id: 104
+        type: boolean
+        name: button
+  - entity: sensor
+    class: temperature
+    category: diagnostic
+    dps:
+      - id: 105
+        type: integer
+        name: sensor
+        unit: C
+        class: measurement
+  - entity: sensor
+    name: Fan speed
+    category: diagnostic
+    dps:
+      - id: 106
+        type: integer
+        name: sensor
+        unit: rpm
+        class: measurement
+        precision: 0
+        mapping:
+          - scale: 0.016667
+  - entity: sensor
+    class: enum
+    translation_key: status
+    dps:
+      - id: 107
+        type: string
+        name: sensor
+        mapping:
+          - dps_val: power_on
+            value: working
+          - dps_val: power_off
+            value: "off"
+          - dps_val: booting
+            value: starting
+          - dps_val: shutting
+            value: standby
+          - dps_val: restarting
+            value: resetting
+          - dps_val: forced_off
+            value: close
+          - dps_val: down_failure
+            value: fault
+          - dps_val: on_failuer
+            value: warning
+          - dps_val: forced_failure
+            value: blocked
+  - entity: number
+    translation_key: timer
+    class: duration
+    category: config
+    dps:
+      - id: 108
+        type: integer
+        name: value
+        unit: s
+        range:
+          min: 0
+          max: 86400