**Is your feature request related to a problem? Please describe.**
I've bought …a garage door opener (_TZE200_wfxuhoea) which isn't supported in ZHA.
I managed to get it working by using the quirk shared in the following issue: https://github.com/zigpy/zha-device-handlers/issues/1260 by changing the name in the quirk.
This way I can use the garage door opener as intended and I also can retrieve the status of the door sensor.
However there are 2 huge issues that make the system unusable:
1) On multiple times of the day (sometimes hourly) it sends an "open"-command trough HA. There aren't any automations that may cause this, and even when I disconnect the device from power, HA still tries to open it. I guess this is related to the unadapted quirk.
2) When the power has been cut for some time, the relay is triggered when the device is plugged in again. So when the power recovers after a power outage, the garage door will open.
Obviously those 2 issues make the system completely unsafe as the garage door opens constantly.
**Describe the solution you'd like**
I guess the quirk has to be adapted to this specific device to be able to work correctly.
<details>
```
<summary>Device signature</summary>
```
```yaml
{
"node_descriptor": "NodeDescriptor(logical_type=<LogicalType.Router: 1>, complex_descriptor_available=0, user_descriptor_available=0, reserved=0, aps_flags=0, frequency_band=<FrequencyBand.Freq2400MHz: 8>, mac_capability_flags=<MACCapabilityFlags.AllocateAddress|RxOnWhenIdle|MainsPowered|FullFunctionDevice: 142>, manufacturer_code=4417, maximum_buffer_size=66, maximum_incoming_transfer_size=66, server_mask=10752, maximum_outgoing_transfer_size=66, descriptor_capability_field=<DescriptorCapability.NONE: 0>, *allocate_address=True, *is_alternate_pan_coordinator=False, *is_coordinator=False, *is_end_device=False, *is_full_function_device=True, *is_mains_powered=True, *is_receiver_on_when_idle=True, *is_router=True, *is_security_capable=False)",
"endpoints": {
"1": {
"profile_id": 260,
"device_type": "0x0100",
"in_clusters": [
"0x0000",
"0x0004",
"0x0005",
"0x0006",
"0xef00"
],
"out_clusters": [
"0x000a",
"0x0019"
]
},
"2": {
"profile_id": 260,
"device_type": "0x0402",
"in_clusters": [
"0x0500"
],
"out_clusters": []
},
"242": {
"profile_id": 41440,
"device_type": "0x0061",
"in_clusters": [],
"out_clusters": [
"0x0021"
]
}
},
"manufacturer": "_TZE200_wfxuhoea",
"model": "TS0601",
"class": "ts0601_garage.TuyaGarageSwitchTO"
}
```
</details>
<details>
<summary>Diagnostic information</summary>
```yaml
{
"home_assistant": {
"installation_type": "Home Assistant Core",
"version": "2022.10.5",
"dev": false,
"hassio": false,
"virtualenv": true,
"python_version": "3.9.10",
"docker": false,
"arch": "arm64",
"timezone": "Europe/Brussels",
"os_name": "Darwin",
"os_version": "13.0",
"run_as_root": false
},
"custom_components": {
"spotcast": {
"version": "v3.6.30",
"requirements": [
"spotify_token==1.0.0"
]
},
"mass": {
"version": "2022.8.4",
"requirements": [
"music-assistant==1.8.7"
]
},
"sonoff": {
"version": "3.3.1",
"requirements": [
"pycryptodome>=3.6.6"
]
},
"mczmaestro": {
"version": "0.1.0",
"requirements": [
"websocket-client==0.57.0"
]
},
"xiaomi_miot": {
"version": "0.4.16",
"requirements": [
"construct==2.10.56",
"python-miio>=0.5.6",
"micloud>=0.3"
]
},
"afvalbeheer": {
"version": "5.0.3",
"requirements": [
"rsa",
"pycryptodome"
]
},
"neerslag": {
"version": "2022.07.07.1",
"requirements": []
},
"watchman": {
"version": "0.5.1",
"requirements": [
"prettytable==3.0.0"
]
},
"miwifi": {
"version": "2.8.2",
"requirements": []
},
"hacs": {
"version": "1.28.0",
"requirements": [
"aiogithubapi>=22.2.4"
]
},
"xiaomi_cloud_map_extractor": {
"version": "v2.2.0",
"requirements": [
"pillow",
"pybase64",
"python-miio",
"requests",
"pycryptodome"
]
}
},
"integration_manifest": {
"domain": "zha",
"name": "Zigbee Home Automation",
"config_flow": true,
"documentation": "https://www.home-assistant.io/integrations/zha",
"requirements": [
"bellows==0.34.2",
"pyserial==3.5",
"pyserial-asyncio==0.6",
"zha-quirks==0.0.83",
"zigpy-deconz==0.19.0",
"zigpy==0.51.3",
"zigpy-xbee==0.16.2",
"zigpy-zigate==0.10.2",
"zigpy-znp==0.9.1"
],
"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"
]
}
],
"codeowners": [
"@dmulcahey",
"@adminiuga",
"@puddly"
],
"zeroconf": [
{
"type": "_esphomelib._tcp.local.",
"name": "tube*"
},
{
"type": "_zigate-zigbee-gateway._tcp.local.",
"name": "*zigate*"
},
{
"type": "_zigstar_gw._tcp.local.",
"name": "*zigstar*"
}
],
"dependencies": [
"file_upload"
],
"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": 18996,
"manufacturer": "_TZE200_wfxuhoea",
"model": "TS0601",
"name": "_TZE200_wfxuhoea TS0601",
"quirk_applied": true,
"quirk_class": "ts0601_garage.TuyaGarageSwitchTO",
"manufacturer_code": 4417,
"power_source": "Mains",
"lqi": null,
"rssi": null,
"last_seen": "2022-10-17T12:05:07",
"available": false,
"device_type": "Router",
"signature": {
"node_descriptor": "NodeDescriptor(logical_type=<LogicalType.Router: 1>, complex_descriptor_available=0, user_descriptor_available=0, reserved=0, aps_flags=0, frequency_band=<FrequencyBand.Freq2400MHz: 8>, mac_capability_flags=<MACCapabilityFlags.AllocateAddress|RxOnWhenIdle|MainsPowered|FullFunctionDevice: 142>, manufacturer_code=4417, maximum_buffer_size=66, maximum_incoming_transfer_size=66, server_mask=10752, maximum_outgoing_transfer_size=66, descriptor_capability_field=<DescriptorCapability.NONE: 0>, *allocate_address=True, *is_alternate_pan_coordinator=False, *is_coordinator=False, *is_end_device=False, *is_full_function_device=True, *is_mains_powered=True, *is_receiver_on_when_idle=True, *is_router=True, *is_security_capable=False)",
"endpoints": {
"1": {
"profile_id": 260,
"device_type": "0x0100",
"in_clusters": [
"0x0000",
"0x0004",
"0x0005",
"0x0006",
"0xef00"
],
"out_clusters": [
"0x000a",
"0x0019"
]
},
"2": {
"profile_id": 260,
"device_type": "0x0402",
"in_clusters": [
"0x0500"
],
"out_clusters": []
},
"242": {
"profile_id": 41440,
"device_type": "0x0061",
"in_clusters": [],
"out_clusters": [
"0x0021"
]
}
}
},
"active_coordinator": false,
"entities": [
{
"entity_id": "binary_sensor.garagepoort",
"name": "_TZE200_wfxuhoea TS0601"
},
{
"entity_id": "light.garagepoort",
"name": "_TZE200_wfxuhoea TS0601"
}
],
"neighbors": [],
"endpoint_names": [
{
"name": "ON_OFF_LIGHT"
},
{
"name": "IAS_ZONE"
},
{
"name": "unknown 97 device_type of 0xa1e0 profile id"
}
],
"user_given_name": "Garagepoort",
"device_reg_id": "3a69d3eb16206bc5693f6d6e92defa4e",
"area_id": "garage",
"cluster_details": {
"1": {
"device_type": {
"name": "ON_OFF_LIGHT",
"id": 256
},
"profile_id": 260,
"in_clusters": {
"0x0000": {
"endpoint_attribute": "basic",
"attributes": {
"0x0001": {
"attribute_name": "app_version",
"value": 70
},
"0x0004": {
"attribute_name": "manufacturer",
"value": "_TZE200_wfxuhoea"
},
"0x0005": {
"attribute_name": "model",
"value": "TS0601"
}
},
"unsupported_attributes": {}
},
"0x0004": {
"endpoint_attribute": "groups",
"attributes": {},
"unsupported_attributes": {}
},
"0x0005": {
"endpoint_attribute": "scenes",
"attributes": {},
"unsupported_attributes": {}
},
"0xef00": {
"endpoint_attribute": "tuya_manufacturer",
"attributes": {
"0xef00": {
"attribute_name": "mcu_version",
"value": "1.0.0"
},
"0xef02": {
"attribute_name": "dp_2",
"value": 0
},
"0xef04": {
"attribute_name": "dp_4",
"value": 10
},
"0xef05": {
"attribute_name": "dp_5",
"value": 0
},
"0xef0b": {
"attribute_name": "dp_11",
"value": 1
},
"0xef0c": {
"attribute_name": "dp_12",
"value": 2
}
},
"unsupported_attributes": {}
},
"0x0006": {
"endpoint_attribute": "on_off",
"attributes": {
"0x0000": {
"attribute_name": "on_off",
"value": 0
}
},
"unsupported_attributes": {
"0x4003": {
"attribute_name": "start_up_on_off"
}
}
}
},
"out_clusters": {
"0x000a": {
"endpoint_attribute": "time",
"attributes": {},
"unsupported_attributes": {}
},
"0x0019": {
"endpoint_attribute": "ota",
"attributes": {},
"unsupported_attributes": {}
}
}
},
"2": {
"device_type": {
"name": "IAS_ZONE",
"id": 1026
},
"profile_id": 260,
"in_clusters": {
"0x0500": {
"endpoint_attribute": "ias_zone",
"attributes": {
"0x0001": {
"attribute_name": "zone_type",
"value": 21
},
"0x0002": {
"attribute_name": "zone_status",
"value": 0
}
},
"unsupported_attributes": {
"0x0000": {
"attribute_name": "zone_state"
}
}
}
},
"out_clusters": {}
},
"242": {
"device_type": {
"name": "unknown",
"id": 97
},
"profile_id": 41440,
"in_clusters": {},
"out_clusters": {
"0x0021": {
"endpoint_attribute": "green_power",
"attributes": {},
"unsupported_attributes": {}
}
}
}
}
}
}
```
</details>
<details>
<summary>Additional logs</summary>
```
Paste any additional debug logs here.
Don't remove the extra line breaks outside the ``` marks.
```
</details>
**Additional context**
In the attached image you can see that the device is turned on (ingeschakeld) automatically at 1:47am and again at 2:47. At 1:47 I woke up from the sound of the garage door. I went down and disconnected the device from the mains power. However at 2:47 it got triggered again. Obviously the garage didn't open but this means that HA causes it to open, not the device itself. As there are no automations running to open the garage door, the only thing that may cause this is the quirk (I suppose).
![image](https://user-images.githubusercontent.com/42653485/198589300-425a98d4-a77a-405c-a814-6ba25515128c.png)