-
Notifications
You must be signed in to change notification settings - Fork 721
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add Tuya Siren TS0601 _TZE204_hcxvyxa5
variant
#3361
Add Tuya Siren TS0601 _TZE204_hcxvyxa5
variant
#3361
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## dev #3361 +/- ##
=======================================
Coverage 88.49% 88.49%
=======================================
Files 305 305
Lines 9621 9621
=======================================
Hits 8514 8514
Misses 1107 1107 ☔ View full report in Codecov by Sentry. |
_TZE204_hcxvyxa5
variant
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Working!
At first, I enabled custom quirks in the configuration.yaml in home assistant because I didn't want to wait for the :main update.
zha: enable_quirks: true custom_quirks_path: /config/zha_quirks/
Then I downloaded the custom quirk:
➜ zha_quirks wget https://raw.githubusercontent.com/zigpy/zha-device-handlers/5c993588c79b7708f9ecfc8ad893df6e51d97924/zhaquirks/tuya/ts0601_siren.py
I rebooted, removed and added the _TZE204_hcxvyxa5
device.
Now the device has a switch. If turned on, the device makes a siren noise for ~500ms and turns off again,
Trough "manage zigbee device" I could change some settings by choosing cluster "TuyaMCUSiren" through the attributes
alarm_duration (id: 0x0267)
sets the alarm duration in seconds.- The volume can be changed trough
volume (id: 0x0474)
by setting the value to0
(low
) ,1
(medium
) or to2
(high
) - The melody can be set trough
melody (id: 0x0466)
where the value can be from0
to36
(37
seems to be a duplicate with 0) which varies from classical songs like "Für Elise" (24
) to notification ish/doorbell sounds (11
) to the three alarm siren sounds (0
-2
) where0
is the most alarm one, but they really have a big cheap toy vibe 👶
Melody (dropdown-menu), volume (dropdown-menu) and duration (slider) should be added to the GUI, so everyone can access it.
Thanks for the quick implementation! ✅
Proposed change
This PR adds siren TS0601 _TZE204_hcxvyxa5 into the existing quirk of
TuyaSirenGPP_NoSensors
, and fixes #3255 and fixes #3228.I have confirmed locally that it enables the siren to be toggled like other similar sirens, and I am able to adjust melody and duration via "Manage zigbee device".
Additional information
Checklist
pre-commit
checks pass / the code has been formatted using Black