Explorar el Código

feat(devices): add support for Alen BreatheSmart 45i air purifier

Issue #3674
Jason Rumney hace 4 meses
padre
commit
2ce8f29a56
Se han modificado 3 ficheros con 116 adiciones y 1 borrados
  1. 1 0
      ACKNOWLEDGEMENTS.md
  2. 1 1
      DEVICES.md
  3. 114 0
      custom_components/tuya_local/devices/alen_45i_airpurifier.yaml

+ 1 - 0
ACKNOWLEDGEMENTS.md

@@ -1052,3 +1052,4 @@ Further device support has been made with the assistance of users. Please consid
 - [swarshah](https://github.com/swarshah) for contributing support for 4-in-1 10GHz motion sensor.
 - [fragpic](https://github.com/fragpic) for assisting with support for AM24 venetian blinds motor.
 - [rachinibop](https://github.com/rachinibop) for assisting with support for SunnyBot plant light.
+- [chucknorris101](https://github.com/chucknorris101) for assisting with support for Alen Breathesmart 45i air purifier.

+ 1 - 1
DEVICES.md

@@ -343,7 +343,7 @@
 
 ### Air Purifiers
 
-- Alen BreatheSmart 35i air purifier
+- Alen BreatheSmart 35i and 45i air purifiers
 - Arlec APR005HA air purifier
 - Breville Easy Air, Smart Air Connect, Smart Air Viral Protect Plus purifiers
 - Cleverio AP100 air purifier

+ 114 - 0
custom_components/tuya_local/devices/alen_45i_airpurifier.yaml

@@ -0,0 +1,114 @@
+name: Air Purifier
+products:
+  - id: Ng7UnT2dUDgIyJL9
+    manufacturer: Alen
+    model: BreatheSmart 45i
+entities:
+  - entity: fan
+    translation_only_key: fan_with_presets
+    dps:
+      - id: 1
+        type: boolean
+        name: switch
+      - id: 4
+        type: string
+        name: speed
+        mapping:
+          - dps_val: "1"
+            value: 25
+          - dps_val: "2"
+            value: 50
+          - dps_val: "3"
+            value: 75
+          - dps_val: "4"
+            value: 100
+      - id: 3
+        type: string
+        name: preset_mode
+        mapping:
+          - dps_val: Manual
+            value: custom
+          - dps_val: Auto
+            value: smart
+          - dps_val: Sleep
+            value: sleep
+  - entity: sensor
+    class: pm25
+    dps:
+      - id: 2
+        type: integer
+        name: sensor
+        unit: µg/m³
+        class: measurement
+  - entity: sensor
+    name: Filter life
+    dps:
+      - id: 5
+        type: integer
+        name: sensor
+        unit: "%"
+        class: measurement
+  - entity: switch
+    translation_key: ionizer
+    category: config
+    dps:
+      - id: 6
+        type: boolean
+        name: switch
+  - entity: lock
+    translation_key: child_lock
+    category: config
+    dps:
+      - id: 7
+        type: boolean
+        name: lock
+  - entity: sensor
+    name: Total runtime
+    class: duration
+    category: diagnostic
+    dps:
+      - id: 17
+        type: integer
+        name: sensor
+        unit: min
+        class: measurement
+  - entity: select
+    translation_key: timer
+    category: config
+    dps:
+      - id: 19
+        type: string
+        name: option
+        mapping:
+          - dps_val: "0"
+            value: cancel
+          - dps_val: "1"
+            value: "2h"
+          - dps_val: "2"
+            value: "4h"
+          - dps_val: "3"
+            value: "12h"
+  - entity: sensor
+    translation_key: time_remaining
+    class: duration
+    category: diagnostic
+    dps:
+      - id: 20
+        type: integer
+        optional: true
+        name: sensor
+        unit: min
+  - entity: binary_sensor
+    class: problem
+    category: diagnostic
+    dps:
+      - id: 21
+        type: bitfield
+        name: sensor
+        mapping:
+          - dps_val: 0
+            value: false
+          - value: true
+      - id: 21
+        type: bitfield
+        name: fault_code