Skip to content

Commit

Permalink
ZX G30 alarm: add names to prviously unknown dps
Browse files Browse the repository at this point in the history
Split out known functions into entities.
Correct charge_state to be binary sensor, not switch.

Issue #1673
  • Loading branch information
make-all committed Feb 22, 2024
1 parent 8cfebd2 commit 4d359f9
Showing 1 changed file with 49 additions and 24 deletions.
73 changes: 49 additions & 24 deletions custom_components/tuya_local/devices/zx_g30_alarm.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,43 +15,44 @@ primary_entity:
value: armed_away
- dps_val: home
value: armed_home
- id: 20
type: boolean
name: unknown_20
- id: 21
type: boolean
name: unknown_21
- id: 22
type: integer
name: unknown_22
name: call_looptimes
- id: 23
type: string
name: unknown_23
name: telnet_state
- id: 24
type: string
name: unknown_24
- id: 32
type: string
name: unknown_32
- id: 34
type: boolean
name: unknown_34
name: zone_attribute
- id: 35
type: boolean
name: unknown_35
name: sub_add
- id: 36
type: string
name: unknown_36
name: sub_class
- id: 37
type: string
name: unknown_37
name: sub_type
- id: 39
type: string
name: unknown_39
name: sub_state
- id: 40
type: string
name: unknown_40
name: master_language
secondary_entities:
- entity: binary_sensor
name: Alarm
class: sound
icon: "mdi:alarm-bell"
dps:
- id: 32
type: string
name: sensor
mapping:
- dps_val: normal
value: false
- dps_val: alarm
value: true
- entity: button
deprecated: alarm_control_panel
category: config
Expand Down Expand Up @@ -134,14 +135,13 @@ secondary_entities:
- id: 10
type: boolean
name: switch
- entity: switch
name: AC power
- entity: binary_sensor
class: plug
category: config
icon: "mdi:current-ac"
dps:
- id: 15
type: boolean
name: switch
name: sensor
- entity: sensor
class: battery
dps:
Expand All @@ -157,6 +157,22 @@ secondary_entities:
- id: 17
type: boolean
name: sensor
- entity: switch
name: Alarm call
category: config
icon: "mdi:phone-alert"
dps:
- id: 20
type: boolean
name: switch
- entity: switch
name: Alarm SMS
category: config
icon: "mdi:message-alert"
dps:
- id: 21
type: boolean
name: switch
- entity: switch
name: Alarm notification
category: config
Expand All @@ -182,3 +198,12 @@ secondary_entities:
- id: 29
type: boolean
name: switch
- entity: button
name: Factory reset
class: restart
category: config
dps:
- id: 34
type: boolean
name: button

Check failure on line 209 in custom_components/tuya_local/devices/zx_g30_alarm.yaml

View workflow job for this annotation

GitHub Actions / lint

209:1 [trailing-spaces] trailing spaces

0 comments on commit 4d359f9

Please sign in to comment.