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
752 stars 688 forks source link

[Device Support Request] LoraTap 4 button remote control #1723

Closed bsafh closed 1 year ago

bsafh commented 2 years ago

Is your feature request related to a problem? Please describe. This remote control (4- button version) shows up after pairing, but without any functionality: the battery is shown, but with level "unknown", and none of the switches show up.

There is a TuyaRemoteControl quirk activated, but it does not fit this device.

Describe the solution you'd like I would like to be able to use this remote control (4 buttons, 12 switch (short press, double press, long press per button)

Device signature ```yaml { "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": "0x0006", "in_clusters": [ "0x0000", "0x0001" ], "out_clusters": [ "0x0006", "0x000a", "0x0019" ] }, "2": { "profile_id": 260, "device_type": "0x0006", "in_clusters": [], "out_clusters": [ "0x0006", "0xe000" ] }, "3": { "profile_id": 260, "device_type": "0x0006", "in_clusters": [], "out_clusters": [ "0x0006", "0xe000" ] }, "4": { "profile_id": 260, "device_type": "0x0006", "in_clusters": [], "out_clusters": [ "0x0006", "0xe000" ] } }, "manufacturer": "_TZ3000_ee8nrt2l", "model": "TS0044", "class": "zhaquirks.tuya.ts0044.TuyaSmartRemote0044TOPlusB" } ```
Diagnostic information ```yaml { "home_assistant": { "installation_type": "Home Assistant Supervised", "version": "2022.8.7", "dev": false, "hassio": true, "virtualenv": false, "python_version": "3.10.5", "docker": true, "arch": "x86_64", "timezone": "Europe/Berlin", "os_name": "Linux", "os_version": "5.10.0-17-amd64", "supervisor": "2022.08.5", "host_os": "Debian GNU/Linux 11 (bullseye)", "docker_version": "20.10.17", "chassis": "vm", "run_as_root": true }, "custom_components": { "hacs": { "version": "1.26.2", "requirements": [ "aiogithubapi>=22.2.4" ] }, "openweathermap_all": { "version": "0.0.1", "requirements": [ "owm2json==0.1.89" ] }, "climate_group": { "version": "0.4.2", "requirements": [] }, "holidays": { "version": "1.8.0", "requirements": [ "python-dateutil>=2.8.2", "holidays>=0.14.2" ] }, "openwrt": { "version": "0.0.1", "requirements": [] }, "homematicip_local": { "version": "1.15.0", "requirements": [ "hahomematic==2022.8.10" ] }, "truenas": { "version": "0.0.0", "requirements": [] }, "nodered": { "version": "1.0.9", "requirements": [] }, "ai_thermostat": { "version": "0.9.3", "requirements": [] }, "browser_mod": { "version": "1.5.3", "requirements": [] }, "better_thermostat": { "version": "1.0.0-beta14", "requirements": [] }, "ferienapidotde": { "version": "0.2.3", "requirements": [ "ferien-api==0.3.6" ] }, "climate_scheduler": { "version": "0.1.0", "requirements": [] }, "webrtc": { "version": "v2.3.1", "requirements": [] }, "gismeteo": { "version": "2.5.0", "requirements": [] }, "frigate": { "version": "2.3", "requirements": [] }, "zha_toolkit": { "version": "v0.8.13", "requirements": [] }, "reversotts": { "version": "1.0.2", "requirements": [ "pyttsreverso==0.4" ] }, "picotts_remote": { "version": "1.0.1", "requirements": [] }, "scheduler": { "version": "v0.0.0", "requirements": [] }, "dwd_weather": { "version": "1.2.22", "requirements": [ "simple_dwd_weatherforecast==1.1.5", "markdownify==0.6.5" ] }, "shelly": { "version": "1.0.1", "requirements": [ "pyShelly==1.0.2", "paho-mqtt==1.6.1", "websocket-client" ] }, "opnsense": { "version": "0.1.0", "requirements": [ "mac-vendor-lookup>=0.1.11" ] }, "dwains_dashboard": { "version": "3.2.0", "requirements": [] } }, "integration_manifest": { "domain": "zha", "name": "Zigbee Home Automation", "config_flow": true, "documentation": "https://www.home-assistant.io/integrations/zha", "requirements": [ "bellows==0.33.1", "pyserial==3.5", "pyserial-asyncio==0.6", "zha-quirks==0.0.78", "zigpy-deconz==0.18.0", "zigpy==0.50.2", "zigpy-xbee==0.15.0", "zigpy-zigate==0.9.2", "zigpy-znp==0.8.2" ], "usb": [ { "vid": "10C4", "pid": "EA60", "description": "*2652*", "known_devices": [ "slae.sh cc2652rb stick" ] }, { "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" ] } ], "codeowners": [ "@dmulcahey", "@adminiuga", "@puddly" ], "zeroconf": [ { "type": "_esphomelib._tcp.local.", "name": "tube*" }, { "type": "_zigate-zigbee-gateway._tcp.local.", "name": "*zigate*" } ], "after_dependencies": [ "onboarding", "usb", "zeroconf" ], "iot_class": "local_polling", "loggers": [ "aiosqlite", "bellows", "crccheck", "pure_pcapy3", "zhaquirks", "zigpy", "zigpy_deconz", "zigpy_xbee", "zigpy_zigate", "zigpy_znp" ], "is_built_in": true }, "data": { "ieee": "**REDACTED**", "nwk": 58084, "manufacturer": "_TZ3000_ee8nrt2l", "model": "TS0044", "name": "_TZ3000_ee8nrt2l TS0044", "quirk_applied": true, "quirk_class": "zhaquirks.tuya.ts0044.TuyaSmartRemote0044TOPlusB", "manufacturer_code": 4417, "power_source": "Battery or Unknown", "lqi": 91, "rssi": null, "last_seen": "2022-08-30T17:14:02", "available": true, "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": "0x0006", "in_clusters": [ "0x0000", "0x0001" ], "out_clusters": [ "0x0006", "0x000a", "0x0019" ] }, "2": { "profile_id": 260, "device_type": "0x0006", "in_clusters": [], "out_clusters": [ "0x0006", "0xe000" ] }, "3": { "profile_id": 260, "device_type": "0x0006", "in_clusters": [], "out_clusters": [ "0x0006", "0xe000" ] }, "4": { "profile_id": 260, "device_type": "0x0006", "in_clusters": [], "out_clusters": [ "0x0006", "0xe000" ] } } }, "active_coordinator": false, "entities": [ { "entity_id": "sensor.tz3000_ee8nrt2l_ts0044_battery", "name": "_TZ3000_ee8nrt2l TS0044" } ], "neighbors": [], "endpoint_names": [ { "name": "REMOTE_CONTROL" }, { "name": "REMOTE_CONTROL" }, { "name": "REMOTE_CONTROL" }, { "name": "REMOTE_CONTROL" } ], "user_given_name": null, "device_reg_id": "6be8b495b3195dbc641bcb5f7f17b64d", "area_id": null, "cluster_details": { "1": { "device_type": { "name": "REMOTE_CONTROL", "id": 6 }, "profile_id": 260, "in_clusters": { "0x0000": { "endpoint_attribute": "basic", "attributes": {}, "unsupported_attributes": {} }, "0x0001": { "endpoint_attribute": "power", "attributes": {}, "unsupported_attributes": {} } }, "out_clusters": { "0x000a": { "endpoint_attribute": "time", "attributes": {}, "unsupported_attributes": {} }, "0x0019": { "endpoint_attribute": "ota", "attributes": {}, "unsupported_attributes": {} }, "0x0006": { "endpoint_attribute": "TS004X_cluster", "attributes": {}, "unsupported_attributes": {} } } }, "2": { "device_type": { "name": "REMOTE_CONTROL", "id": 6 }, "profile_id": 260, "in_clusters": {}, "out_clusters": { "0x0006": { "endpoint_attribute": "TS004X_cluster", "attributes": {}, "unsupported_attributes": {} }, "0xe000": { "endpoint_attribute": "tuya_is_pita_0", "attributes": {}, "unsupported_attributes": {} } } }, "3": { "device_type": { "name": "REMOTE_CONTROL", "id": 6 }, "profile_id": 260, "in_clusters": {}, "out_clusters": { "0x0006": { "endpoint_attribute": "TS004X_cluster", "attributes": {}, "unsupported_attributes": {} }, "0xe000": { "endpoint_attribute": "tuya_is_pita_0", "attributes": {}, "unsupported_attributes": {} } } }, "4": { "device_type": { "name": "REMOTE_CONTROL", "id": 6 }, "profile_id": 260, "in_clusters": {}, "out_clusters": { "0x0006": { "endpoint_attribute": "TS004X_cluster", "attributes": {}, "unsupported_attributes": {} }, "0xe000": { "endpoint_attribute": "tuya_is_pita_0", "attributes": {}, "unsupported_attributes": {} } } } } } } ```
Additional logs ``` 2022-08-30 17:20:01.802 DEBUG (MainThread) [zigpy_znp.api] Sending request: AF.DataRequestExt.Req(DstAddrModeAddress=AddrModeAddress(mode=, address=a4:c1:38:bd:eb:31:32:bd), DstEndpoint=1, DstPanId=0x0000, SrcEndpoint=1, ClusterId=6, TSN=76, Options=, Radius=30, Data=b'\x18\x4C\x0B\xFD\x00') 2022-08-30 17:21:30.660 DEBUG (MainThread) [zigpy_znp.api] Received command: ZDO.IEEEAddrRsp.Callback(Status=, IEEE=a4:c1:38:bd:eb:31:32:bd, NWK=0xE2E4, NumAssoc=0, Index=0, Devices=[]) 2022-08-30 17:21:30.661 INFO (MainThread) [zigpy.application] New device 0xe2e4 (a4:c1:38:bd:eb:31:32:bd) joined the network 2022-08-30 17:21:30.665 DEBUG (MainThread) [zigpy.application] Received frame on uninitialized device from ep 2 to ep 1, cluster 6: b'\x01\x4D\xFD\x02' 2022-08-30 17:21:30.673 DEBUG (MainThread) [zigpy.application] Received frame on uninitialized device from ep 0 to ep 0, cluster 32769: b'U\x00\xbd21\xeb\xbd8\xc1\xa4\xe4\xe2' 2022-08-30 17:21:30.673 DEBUG (MainThread) [zigpy.zdo] [0xe2e4:zdo] ZDO request ZDOCmd.IEEE_addr_rsp: [, a4:c1:38:bd:eb:31:32:bd, 0xE2E4, None, None, []] 2022-08-30 17:21:30.674 DEBUG (MainThread) [zigpy.zdo] [0xe2e4:zdo] No handler for ZDO request:ZDOCmd.IEEE_addr_rsp([, a4:c1:38:bd:eb:31:32:bd, 0xE2E4, None, None, []]) 2022-08-30 17:21:31.183 DEBUG (MainThread) [zigpy.application] Received frame on uninitialized device from ep 2 to ep 1, cluster 6: b'\x01\x4D\xFD\x02' 2022-08-30 17:21:32.880 DEBUG (MainThread) [zigpy_znp.api] Received command: ZDO.LeaveInd.Callback(NWK=0xE2E4, IEEE=a4:c1:38:bd:eb:31:32:bd, Request=, Remove=, Rejoin=) 2022-08-30 17:21:32.881 INFO (MainThread) [zigpy_znp.zigbee.application] ZDO device left: ZDO.LeaveInd.Callback(NWK=0xE2E4, IEEE=a4:c1:38:bd:eb:31:32:bd, Request=, Remove=, Rejoin=) 2022-08-30 17:21:32.881 INFO (MainThread) [zigpy.application] Device 0xe2e4 (a4:c1:38:bd:eb:31:32:bd) left the network ```

Additional context can be found on Aliexpress here: https://de.aliexpress.com/item/1005003432430621.html

MattWestb commented 2 years ago

Switches and remotes (light controlling devices) is not making any "switches" in ZHA that you can turning on and off as you can doing with light and plugs then they is sending events that is being used in HA automatons. Your device have getting one quirk "class": "zhaquirks.tuya.ts0044.TuyaSmartRemote0044TOPlusB" and also device automatons on the device card that you can using for doing automatons for your device.

You can listening to events the device is sending with zha_event in developer > events > listening to events and putting in zha_event as event type.

github-actions[bot] commented 1 year ago

There hasn't been any activity on this issue recently. Due to the high number of incoming GitHub notifications, we have to clean some of the old issues, as many of them have already been resolved with the latest updates. Please make sure to update to the latest version and check if that solves the issue. Let us know if that works for you by adding a comment 👍 This issue has now been marked as stale and will be closed if no further activity occurs. Thank you for your contributions.