zigpy / zha-device-handlers

ZHA device handlers bridge the functionality gap created when manufacturers deviate from the ZCL specification, handling deviations and exceptions by parsing custom messages to and from Zigbee devices.
Apache License 2.0
683 stars 633 forks source link

[Device Support Request] Tuya TS0203 _TZ3000_au1rjicn Window / Door / Contact Sensor #2352

Open b2un0 opened 1 year ago

b2un0 commented 1 year ago

Is your feature request related to a problem? Please describe. The mentioned device above joined the network and than leave the network after a seconds

https://www.aliexpress.com/item/1005004984273100.html

Describe the solution you'd like working Contact Senor

Device signature ```yaml Paste the device signature here. Don't remove the extra line breaks outside the ``` marks. ```
```json { "home_assistant": { "installation_type": "Home Assistant Container", "version": "2023.4.6", "dev": false, "hassio": false, "virtualenv": false, "python_version": "3.10.10", "docker": true, "arch": "aarch64", "timezone": "Europe/Berlin", "os_name": "Linux", "os_version": "6.1.21-v8+", "run_as_root": true }, "custom_components": { "zha_toolkit": { "version": "v0.8.38", "requirements": [ "packaging>=20.8", "pytz" ] }, "xiaomi_miio_fan": { "version": "2022.8.0.0", "requirements": [ "construct==2.10.56", "python-miio>=0.5.12" ] }, "localtuya": { "version": "5.0.0", "requirements": [] }, "avanza_stock": { "version": "1.2.0", "requirements": [ "pyavanza==0.6.0" ] }, "hacs": { "version": "1.32.1", "requirements": [ "aiogithubapi>=22.10.1" ] }, "auto_backup": { "version": "1.3.2", "requirements": [] } }, "integration_manifest": { "domain": "zha", "name": "Zigbee Home Automation", "after_dependencies": [ "onboarding", "usb" ], "codeowners": [ "@dmulcahey", "@adminiuga", "@puddly" ], "config_flow": true, "dependencies": [ "file_upload" ], "documentation": "https://www.home-assistant.io/integrations/zha", "iot_class": "local_polling", "loggers": [ "aiosqlite", "bellows", "crccheck", "pure_pcapy3", "zhaquirks", "zigpy", "zigpy_deconz", "zigpy_xbee", "zigpy_zigate", "zigpy_znp" ], "requirements": [ "bellows==0.35.1", "pyserial==3.5", "pyserial-asyncio==0.6", "zha-quirks==0.0.97", "zigpy-deconz==0.20.0", "zigpy==0.54.1", "zigpy-xbee==0.17.0", "zigpy-zigate==0.10.3", "zigpy-znp==0.10.0" ], "usb": [ { "vid": "10C4", "pid": "EA60", "description": "*2652*", "known_devices": [ "slae.sh cc2652rb stick" ] }, { "vid": "1A86", "pid": "55D4", "description": "*sonoff*plus*", "known_devices": [ "sonoff zigbee dongle plus v2" ] }, { "vid": "10C4", "pid": "EA60", "description": "*sonoff*plus*", "known_devices": [ "sonoff zigbee dongle plus" ] }, { "vid": "10C4", "pid": "EA60", "description": "*tubeszb*", "known_devices": [ "TubesZB Coordinator" ] }, { "vid": "1A86", "pid": "7523", "description": "*tubeszb*", "known_devices": [ "TubesZB Coordinator" ] }, { "vid": "1A86", "pid": "7523", "description": "*zigstar*", "known_devices": [ "ZigStar Coordinators" ] }, { "vid": "1CF1", "pid": "0030", "description": "*conbee*", "known_devices": [ "Conbee II" ] }, { "vid": "10C4", "pid": "8A2A", "description": "*zigbee*", "known_devices": [ "Nortek HUSBZB-1" ] }, { "vid": "0403", "pid": "6015", "description": "*zigate*", "known_devices": [ "ZiGate+" ] }, { "vid": "10C4", "pid": "EA60", "description": "*zigate*", "known_devices": [ "ZiGate" ] }, { "vid": "10C4", "pid": "8B34", "description": "*bv 2010/10*", "known_devices": [ "Bitron Video AV2010/10" ] } ], "zeroconf": [ { "type": "_esphomelib._tcp.local.", "name": "tube*" }, { "type": "_zigate-zigbee-gateway._tcp.local.", "name": "*zigate*" }, { "type": "_zigstar_gw._tcp.local.", "name": "*zigstar*" }, { "type": "_slzb-06._tcp.local.", "name": "slzb-06*" } ], "is_built_in": true }, "data": { "ieee": "**REDACTED**", "nwk": 1709, "manufacturer": "_TZ3000_au1rjicn", "model": "TS0203", "name": "_TZ3000_au1rjicn TS0203", "quirk_applied": false, "quirk_class": "zigpy.device.Device", "manufacturer_code": 4417, "power_source": "Battery or Unknown", "lqi": 156, "rssi": -61, "last_seen": "2023-04-24T14:26:27", "available": false, "device_type": "EndDevice", "signature": { "node_descriptor": "NodeDescriptor(logical_type=, complex_descriptor_available=0, user_descriptor_available=0, reserved=0, aps_flags=0, frequency_band=, mac_capability_flags=, manufacturer_code=4417, maximum_buffer_size=66, maximum_incoming_transfer_size=66, server_mask=10752, maximum_outgoing_transfer_size=66, descriptor_capability_field=, *allocate_address=True, *is_alternate_pan_coordinator=False, *is_coordinator=False, *is_end_device=True, *is_full_function_device=False, *is_mains_powered=False, *is_receiver_on_when_idle=False, *is_router=False, *is_security_capable=False)", "endpoints": { "1": { "profile_id": 260, "device_type": "0x0402", "in_clusters": [ "0x0000", "0x0001", "0x0003", "0x0500" ], "out_clusters": [ "0x0003", "0x0004", "0x0005", "0x0006", "0x0008", "0x000a", "0x0019", "0x1000" ] } } }, "active_coordinator": false, "entities": [ { "entity_id": "binary_sensor.tz3000_au1rjicn_ts0203_iaszone", "name": "_TZ3000_au1rjicn TS0203" }, { "entity_id": "binary_sensor.tz3000_au1rjicn_ts0203_opening", "name": "_TZ3000_au1rjicn TS0203" }, { "entity_id": "button.tz3000_au1rjicn_ts0203_identify", "name": "_TZ3000_au1rjicn TS0203" }, { "entity_id": "sensor.tz3000_au1rjicn_ts0203_battery", "name": "_TZ3000_au1rjicn TS0203" } ], "neighbors": [], "routes": [], "endpoint_names": [ { "name": "IAS_ZONE" } ], "user_given_name": null, "device_reg_id": "96c1e4e14b5c177cf33bd461e3e57536", "area_id": null, "cluster_details": { "1": { "device_type": { "name": "IAS_ZONE", "id": 1026 }, "profile_id": 260, "in_clusters": { "0x0001": { "endpoint_attribute": "power", "attributes": { "0x0020": { "attribute_name": "battery_voltage", "value": 30 }, "0x0021": { "attribute_name": "battery_percentage_remaining", "value": 200 } }, "unsupported_attributes": { "0x0031": { "attribute_name": "battery_size" }, "0x0033": { "attribute_name": "battery_quantity" } } }, "0x0003": { "endpoint_attribute": "identify", "attributes": {}, "unsupported_attributes": {} }, "0x0500": { "endpoint_attribute": "ias_zone", "attributes": { "0x0000": { "attribute_name": "zone_state", "value": 1 }, "0x0001": { "attribute_name": "zone_type", "value": 21 }, "0x0002": { "attribute_name": "zone_status", "value": 1 }, "0x0010": { "attribute_name": "cie_addr", "value": [ 27, 38, 4, 255, 255, 46, 33, 0 ] } }, "unsupported_attributes": {} }, "0x0000": { "endpoint_attribute": "basic", "attributes": { "0x0004": { "attribute_name": "manufacturer", "value": "_TZ3000_au1rjicn" }, "0x0005": { "attribute_name": "model", "value": "TS0203" } }, "unsupported_attributes": {} } }, "out_clusters": { "0x0003": { "endpoint_attribute": "identify", "attributes": {}, "unsupported_attributes": {} }, "0x0004": { "endpoint_attribute": "groups", "attributes": {}, "unsupported_attributes": {} }, "0x0005": { "endpoint_attribute": "scenes", "attributes": {}, "unsupported_attributes": {} }, "0x0006": { "endpoint_attribute": "on_off", "attributes": { "0x0000": { "attribute_name": "on_off", "value": 0 } }, "unsupported_attributes": { "0x4003": { "attribute_name": "start_up_on_off" } } }, "0x0008": { "endpoint_attribute": "level", "attributes": {}, "unsupported_attributes": {} }, "0x1000": { "endpoint_attribute": "lightlink", "attributes": {}, "unsupported_attributes": {} }, "0x0019": { "endpoint_attribute": "ota", "attributes": {}, "unsupported_attributes": {} }, "0x000a": { "endpoint_attribute": "time", "attributes": {}, "unsupported_attributes": {} } } } } } } ```
Additional logs [home-assistant_zha_2023-04-24T12-26-36.672Z.log](https://github.com/zigpy/zha-device-handlers/files/11310402/home-assistant_zha_2023-04-24T12-26-36.672Z.log)

image

gielk commented 1 year ago

+1

tOOmki commented 1 year ago

+1

MaxMSchneider commented 1 year ago

+1

Qianli-Ma commented 1 year ago

I believe that the contact sensor is working as expected buy not the tamper sensor?

Malte1992 commented 1 year ago

Is it possible to integrate the sensor via zha in the meantime?

MattWestb commented 1 year ago

I believe that the contact sensor is working as expected buy not the tamper sensor?

My experience with LIDL devices is that the tamper is being sent but (Z)HA is not using it and if temper is open and one alarm is being triggered and then the tamper is being retested the alarm reset is being lost and is staying in alarm mode in the HA GUI. I think ZHA need implanting the tamper and fixing the logic of the reset of it and the alarm for getting it working OK.

All my LIDL devices is working OK if getting the tamper being in sync for not braking the alarm commands sent.

wmcleanutas commented 11 months ago

+1

EnricoBettella commented 10 months ago

+1

EnricoBettella commented 10 months ago

I believe that the contact sensor is working as expected buy not the tamper sensor?

That's the exact issue i'm facing with my ZD08 sensors. Anyway, I think the op problem is with slightly different devices, since those of the aliexpress page linked above don't have the tamper sensor. They seems to appear always as "TS0203" though.

cramer52 commented 8 months ago

I added two TS0203 _TZ3000_au1rjicn contact sensors roughly 6 months ago without any issues and they have been working flawless since. Today I tried to add a new one (bought from the same vendor) and it's not showing the ias_zone sensor anymore just two 'Opening' sensors which are not responding. I get a "failed to bind the 'ias_zone' cluster" in the Debug. Any idea why this might be the case or how to approach the issue @MattWestb? If you need more informations I'll try to provide it.

MaxMSchneider commented 8 months ago

@cramer52 @b2un0 I had the same issue, also with a Skyconnect. Just today I stumbled across this fix, which made all my pairing problems vanish. A firmware update did the trick.

See more here: https://github.com/home-assistant/core/issues/98624#issuecomment-1688222346

MaxMSchneider commented 8 months ago

@cramer52 @b2un0 I had the same issue, also with a Skyconnect. Just today I stumbled across this fix, which made all my pairing problems vanish. A firmware update did the trick.

See more here: https://github.com/home-assistant/core/issues/98624#issuecomment-1688222346

Add: The pairing issues have been resolved, but I've been a bit overly excited. The door sensor still drops out of the network after some time.

MattWestb commented 8 months ago

@MaxMSchneider Look what parent is having in the network it can that is not liking it and trying jumping to one other that also is not working well (like Philips HUE motions is doing all the time).

cramer52 commented 8 months ago

@MaxMSchneider @MattWestb I use a sonoff cc2652p dongle and with the latest firmware update I paired it (didn't work right away but with a few tries it finally paired) and it seems to be working fine for the past day with several restarts etc.

darth-hp commented 5 months ago

I used ZHA Toolkit rejoin with success. Just run it until blinking stops several times. I had the same issue after upgrade from Conbee II to III.

Jumperm commented 3 months ago

I'm using the Sonoff Dongle E with EmberZnet NCP 7.4.1.0 and having still problems to add the TS0203 _TZ3000_au1rjicn. It's been detected but the initial configuration fail.

With Z2M and an conbee II it work out of the box!

Any solution or alternativ door/windows sensors for ZHA with EZSP?!

Jumperm commented 3 months ago

After forgot to configure it again it works. I put some batteries instead of battery packs in it. Maybe that's a big problem...