Browse Source

Add support for Orion indoor siren. Remove broken camera

Issue #1743, #1744

- previously added camera has no non-optional dps so cannot be
  detected. As no info was supplied in the report, there is no way
  forward for a fix, and also there are issues listed in the report
  that are likely linked to this.
Jason Rumney 1 năm trước cách đây
mục cha
commit
e90266ee1e

+ 1 - 1
ACKNOWLEDGEMENTS.md

@@ -718,5 +718,5 @@ Further device support has been made with the assistance of users. Please consid
 - [fotis3d](https://github.com/fotis3d) for assisting with support for Digoo HamB alarm.
 - [Igooris](https://github.com/Igooris) for contributing support for PZIOT E01 energy meter.
 - [shadowkora](https://github.com/shadowkora) for assisting with support for Moes Smart control panel mini IR/Bluetooth hub.
-- [megarch2021](https://github.com/megarch2021) for contributing support for Orion SC009HA cameras.
+- [megarch2021](https://github.com/megarch2021) for contributing support for Orion SWS07HA indoor siren.
 - [markussiegert](https://github.com/markussiegery) for assisting with support for smoke detector.

+ 1 - 1
DEVICES.md

@@ -701,6 +701,7 @@ work reliably, even if listed below.
 ### Sirens
 
 - Neo Coolcam Siren with temperature and humidity alert (NAS-AB02W)
+- Orion Grid Connect SWS07HA indoor siren
 - Orion Grid Connect outdoor siren (also Elesion NX-4980)
 - Sirena WS-902 Plus outdoor strobe siren
 - STL siren
@@ -728,7 +729,6 @@ port and password.
 - Kerui JS-P162 300W camera
 - LSC PTZ camera
 - Nedis outdoor camera
-- Orions SC009HA cameras
 - Pinelake BF02 birdfeeder camera
 - RL video intercom (reported unable to connect)
 

+ 58 - 0
custom_components/tuya_local/devices/orion_indoor_siren.yaml

@@ -0,0 +1,58 @@
+name: Indoor Siren
+products:
+  - id: yytgthb3nxt1zp0e
+    name: Orion SWS07HA
+primary_entity:
+  entity: siren
+  dps:
+    - id: 1
+      name: tone
+      type: string
+      mapping:
+        - dps_val: alarm_sound
+          value: sound
+          default: true
+        - dps_val: normal
+          value: "off"
+    - id: 5
+      name: volume_level
+      type: string
+      mapping:
+        - dps_val: low
+          value: 0.33
+        - dps_val: middle
+          value: 0.67
+        - dps_val: high
+          value: 1.0
+    - id: 7
+      name: duration
+      type: integer
+      range:
+        min: 0
+        max: 4
+      unit: min
+
+secondary_entities:
+  - entity: alarm_control_panel
+    dps:
+      - id: 4
+        type: boolean
+        name: alarm_state
+        mapping:
+          - dps_val: true
+            value: armed_away
+          - dps_val: false
+            value: disarmed
+  - entity: select
+    name: Mode
+    dps:
+      - id: 19
+        type: string
+        name: option
+        mapping:
+          - dps_val: "SOUND"
+            value: "Sound"
+          - dps_val: "Sound_Light"
+            value: "Sound+light"
+          - dps_val: "LINGHT"
+            value: "Light"

+ 0 - 189
custom_components/tuya_local/devices/orion_sc009ha_camera.yaml

@@ -1,189 +0,0 @@
-name: Indoor Camera
-products:
-  - id: uhvuchdkaimx0hfu
-    name: Orion SC009HA1
-  - id: 2g8r2qybiaxbl9xx
-    name: Orion SC009HA2
-primary_entity:
-  entity: camera
-  dps:
-    - id: 134
-      type: boolean
-      name: motion_enable
-      optional: true
-    - id: 150
-      type: boolean
-      name: record
-      optional: true
-    - id: 115
-      type: base64
-      optional: true
-      sensitive: true
-      name: snapshot
-    - id: 105
-      type: boolean
-      name: switch
-      optional: true
-      mapping:
-        - dps_val: true
-          value: false
-        - dps_val: false
-          value: true
-        - dps_val: null
-          value: true
-secondary_entities:
-  - entity: light
-    class: indicator
-    dps:
-      - id: 101
-        type: boolean
-        name: switch
-        optional: true
-  - entity: switch
-    name: Flip image
-    icon: "mdi:flip-horizontal"
-    dps:
-      - id: 103
-        type: boolean
-        name: switch
-        optional: true
-  - entity: switch
-    name: Timestamp
-    icon: "mdi:clock-time-eight"
-    dps:
-      - id: 104
-        type: boolean
-        name: switch
-        optional: true
-  - entity: select
-    name: Motion sensitivity
-    icon: "mdi:motion-sensor"
-    dps:
-      - id: 106
-        type: string
-        name: option
-        optional: true
-        mapping:
-          - dps_val: 0
-            value: Low
-          - dps_val: 1
-            value: Medium
-          - dps_val: 2
-            value: High
-          - dps_val: null
-            value: High
-  - entity: select
-    name: Night vision
-    icon: "mdi:weather-night"
-    dps:
-      - id: 108
-        type: string
-        name: option
-        optional: true
-        mapping:
-          - dps_val: 0
-            value: auto
-          - dps_val: 1
-            value: "off"
-          - dps_val: 2
-            value: "on"
-          - dps_val: null
-            value: "off"
-  - entity: button
-    name: SD format
-    icon: "mdi:micro-sd"
-    dps:
-      - id: 111
-        type: boolean
-        name: button
-        optional: true
-  - entity: button
-    name: PTZ stop
-    icon: "mdi:stop-circle"
-    dps:
-      - id: 116
-        type: boolean
-        name: button
-        optional: true
-  - entity: select
-    name: PTZ control
-    icon: "mdi:cursor-move"
-    dps:
-      - id: 119
-        type: string
-        name: option
-        optional: true
-        mapping:
-          - dps_val: 0
-            value: up
-          - dps_val: 1
-            value: right-up
-          - dps_val: 2
-            value: right
-          - dps_val: 3
-            value: right-down
-          - dps_val: 4
-            value: down
-          - dps_val: 5
-            value: left-down
-          - dps_val: 6
-            value: left
-          - dps_val: 7
-            value: left-up
-  - entity: switch
-    name: Sound detection
-    icon: "mdi:ear-hearing"
-    dps:
-      - id: 139
-        type: boolean
-        name: switch
-        optional: true
-  - entity: select
-    name: Sound sensitivity
-    icon: "mdi:ear-hearing"
-    dps:
-      - id: 140
-        type: string
-        name: option
-        optional: true
-        mapping:
-          - dps_val: 0
-            value: Low
-          - dps_val: 1
-            value: High
-        # following should be a binary_sensor, but we don't know the mapping
-        # if it is another snapshot, then it should be moved to camera and
-        # snapshot made to redirect when null
-      - id: 141
-        type: string
-        name: sensor
-        optional: true
-  - entity: select
-    name: Recording mode
-    icon: "mdi:video"
-    dps:
-      - id: 151
-        type: string
-        name: option
-        optional: true
-        mapping:
-          - dps_val: 1
-            value: Event
-          - dps_val: 2
-            value: Continuous
-  - entity: switch
-    name: Motion tracking
-    icon: "mdi:motion-sensor"
-    dps:
-      - id: 161
-        type: boolean
-        name: switch
-        optional: true
-  - entity: switch
-    name: Human filter
-    icon: "mdi:human-male-female"
-    dps:
-      - id: 170
-        type: boolean
-        name: switch
-        optional: true