We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
[Device Support Request]
**Is your feature request related to a problem? Please describe.**

When my zigbee is discovered (_TZE200_tviaymwx ) by the Zigbee Home Automation integration Home Assistant, it's not properly recognized. Is not using the propew Quirk (TuyaSingleSwitchTO) and thus, is nos showing the proper controls. This is a new variant of the same 1 gang switch.

![image](https://user-images.githubusercontent.com/16512477/154132535-155d3af9-ef5d-4619-ad5e-28887e000553.png)


**Describe the solution you'd like**
I like the device to be discovered properly and with the proper quirkc attached like this other one

![image](https://user-images.githubusercontent.com/16512477/154132803-59650e5e-3210-4db2-9eda-08c502f48a4c.png)


**Device signature - this can be acquired by removing the device from ZHA and pairing it again from the add devices screen. Be sure to add the entire content of the log panel after pairing the device to a code block below this line.**

```
{
  "node_descriptor": "NodeDescriptor(logical_type=<LogicalType.EndDevice: 2>, complex_descriptor_available=0, user_descriptor_available=0, reserved=0, aps_flags=0, frequency_band=<FrequencyBand.Freq2400MHz: 8>, mac_capability_flags=<MACCapabilityFlags.AllocateAddress: 128>, manufacturer_code=4098, maximum_buffer_size=82, maximum_incoming_transfer_size=82, server_mask=11264, maximum_outgoing_transfer_size=82, descriptor_capability_field=<DescriptorCapability.NONE: 0>, *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": "0x0051",
      "in_clusters": [
        "0x0000",
        "0x0004",
        "0x0005",
        "0xef00"
      ],
      "out_clusters": [
        "0x000a",
        "0x0019"
      ]
    }
  },
  "manufacturer": "_TZE200_tviaymwx",
  "model": "TS0601",
  "class": "zigpy.device.Device"
}
```

**Additional context**
Add any other context or screenshots about the feature request here.


--- END ISSUE ---

Below are some code segments, each from a relevant file. One or more of these files may contain bugs.
--- BEGIN FILES ---
Path: `zhaquirks/tuya/ts0601_switch.py`
Content:
```
1 """Tuya DP based switches."""
2 from zigpy.profiles import zha
3 from zigpy.zcl.clusters.general import Basic, Groups, Ota, Scenes, Time
4 
5 from zhaquirks.const import (
6     DEVICE_TYPE,
7     ENDPOINTS,
8     INPUT_CLUSTERS,
9     MODELS_INFO,
10     OUTPUT_CLUSTERS,
11     PROFILE_ID,
12 )
13 from zhaquirks.tuya import (
14     TuyaManufacturerClusterOnOff,
15     TuyaManufCluster,
16     TuyaOnOff,
17     TuyaSwitch,
18 )
19 
20 
21 class TuyaSingleSwitchTI(TuyaSwitch):
22     """Tuya single channel switch time on in cluster device."""
23 
24     signature = {
25         # "node_descriptor": "<NodeDescriptor byte1=1 byte2=64 mac_capability_flags=142 manufacturer_code=4098
26         #                       maximum_buffer_size=82 maximum_incoming_transfer_size=82 server_mask=11264
27         #                       maximum_outgoing_transfer_size=82 descriptor_capability_field=0>",
28         # device_version=1
29         # input_clusters=[0x0000,0x0004, 0x0005,0x000a, 0xef00]
30         # output_clusters=[0x0019]
31         # <SimpleDescriptor endpoint=1 profile=260 device_type=81 device_version=1 input_clusters=[0, 4, 5, 10, 61184] output_clusters=[25]>
32         MODELS_INFO: [("_TZE200_7tdtqgwv", "TS0601")],
33         ENDPOINTS: {
34             1: {
35                 PROFILE_ID: zha.PROFILE_ID,
36                 DEVICE_TYPE: zha.DeviceType.SMART_PLUG,
37                 INPUT_CLUSTERS: [
38                     Basic.cluster_id,
39                     Groups.cluster_id,
40                     Scenes.cluster_id,
41                     Time.cluster_id,
42                     TuyaManufCluster.cluster_id,
43                 ],
44                 OUTPUT_CLUSTERS: [Ota.cluster_id],
45             }
46         },
47     }
48 
49     replacement = {
50         ENDPOINTS: {
51             1: {
52                 DEVICE_TYPE: zha.DeviceType.ON_OFF_LIGHT,
53                 INPUT_CLUSTERS: [
54                     Basic.cluster_id,
55                     Time.cluster_id,
56                     Groups.cluster_id,
57                     Scenes.cluster_id,
58                     TuyaManufacturerClusterOnOff,
59                     TuyaOnOff,
60                 ],
61                 OUTPUT_CLUSTERS: [Ota.cluster_id],
62             }
63         }
64     }
65 
66 
67 class TuyaSingleSwitchTO(TuyaSwitch):
68     """Tuya single channel switch time on out cluster device."""
69 
70     signature = {
71         # "node_descriptor": "<NodeDescriptor byte1=1 byte2=64 mac_capability_flags=142 manufacturer_code=4098
72         #                       maximum_buffer_size=82 maximum_incoming_transfer_size=82 server_mask=11264
73         #                       maximum_outgoing_transfer_size=82 descriptor_capability_field=0>",
74         # device_version=1
75         # input_clusters=[0x0000, 0x0004, 0x0005, 0xef00]
76         # output_clusters=[0x000a, 0x0019]
77         # <SimpleDescriptor endpoint=1 profile=260 device_type=51 device_version=1 input_clusters=[0, 4, 5, 61184] output_clusters=[10, 25]>
78         MODELS_INFO: [
79             ("_TZE200_amp6tsvy", "TS0601"),
80             ("_TZE200_oisqyl4o", "TS0601"),
81             ("_TZE200_vhy3iakz", "TS0601"),  # ¿1 or 4 gangs?
82             ("_TZ3000_uim07oem", "TS0601"),  # ¿1 or 4 gangs?
83             ("_TZE200_wfxuhoea", "TS0601"),
84         ],
85         ENDPOINTS: {
86             1: {
87                 PROFILE_ID: zha.PROFILE_ID,
88                 DEVICE_TYPE: zha.DeviceType.SMART_PLUG,
89                 INPUT_CLUSTERS: [
90                     Basic.cluster_id,
91                     Groups.cluster_id,
92                     Scenes.cluster_id,
93                     TuyaManufCluster.cluster_id,
94                 ],
95                 OUTPUT_CLUSTERS: [Time.cluster_id, Ota.cluster_id],
96             }
97         },
98     }
99 
100     replacement = {
101         ENDPOINTS: {
102             1: {
103                 DEVICE_TYPE: zha.DeviceType.ON_OFF_LIGHT,
104                 INPUT_CLUSTERS: [
105                     Basic.cluster_id,
106                     Groups.cluster_id,
107                     Scenes.cluster_id,
108                     TuyaManufacturerClusterOnOff,
109                     TuyaOnOff,
110                 ],
111                 OUTPUT_CLUSTERS: [Time.cluster_id, Ota.cluster_id],
112             }
113         }
114     }
115 
116 
117 class TuyaDoubleSwitchTO(TuyaSwitch):
118     """Tuya double channel switch time on out cluster device."""
119 
120     signature = {
121         # "node_descriptor": "<NodeDescriptor byte1=1 byte2=64 mac_capability_flags=142 manufacturer_code=4098
122         #                       maximum_buffer_size=82 maximum_incoming_transfer_size=82 server_mask=11264
123         #                       maximum_outgoing_transfer_size=82 descriptor_capability_field=0>",
124         # device_version=1
125         # input_clusters=[0x0000, 0x0004, 0x0005, 0xef00]
126         # output_clusters=[0x000a, 0x0019]
127         # <SimpleDescriptor endpoint=1 profile=260 device_type=51 device_version=1 input_clusters=[0, 4, 5, 61184] output_clusters=[10, 25]>
128         MODELS_INFO: [
129             ("_TZE200_g1ib5ldv", "TS0601"),
130             ("_TZE200_wunufsil", "TS0601"),
131         ],
132         ENDPOINTS: {
133             1: {
134                 PROFILE_ID: zha.PROFILE_ID,
135                 DEVICE_TYPE: zha.DeviceType.SMART_PLUG,
136                 INPUT_CLUSTERS: [
137                     Basic.cluster_id,
138                     Groups.cluster_id,
139                     Scenes.cluster_id,
140                     TuyaManufCluster.cluster_id,
141                 ],
142                 OUTPUT_CLUSTERS: [Time.cluster_id, Ota.cluster_id],
143             }
144         },
145     }
146 
147     replacement = {
148         ENDPOINTS: {
149             1: {
150                 DEVICE_TYPE: zha.DeviceType.ON_OFF_LIGHT,
151                 INPUT_CLUSTERS: [
152                     Basic.cluster_id,
153                     Groups.cluster_id,
154                     Scenes.cluster_id,
155                     TuyaManufacturerClusterOnOff,
156                     TuyaOnOff,
157                 ],
158                 OUTPUT_CLUSTERS: [Time.cluster_id, Ota.cluster_id],
159             },
160             2: {
161                 PROFILE_ID: zha.PROFILE_ID,
162                 DEVICE_TYPE: zha.DeviceType.ON_OFF_LIGHT,
163                 INPUT_CLUSTERS: [
164                     TuyaOnOff,
165                 ],
166                 OUTPUT_CLUSTERS: [],
167             },
168         }
169     }
170 
171 
172 class TuyaTripleSwitchTO(TuyaSwitch):
173     """Tuya triple channel switch time on out cluster device."""
174 
175     signature = {
176         MODELS_INFO: [
177             # ("_TZE200_kyfqmmyl", "TS0601"),  ## candidate reported in #716
178             ("_TZE200_tz32mtza", "TS0601"),
179         ],
180         ENDPOINTS: {
181             1: {
182                 PROFILE_ID: zha.PROFILE_ID,
183                 DEVICE_TYPE: zha.DeviceType.SMART_PLUG,
184                 INPUT_CLUSTERS: [
185                     Basic.cluster_id,
186                     Groups.cluster_id,
187                     Scenes.cluster_id,
188                     TuyaManufCluster.cluster_id,
189                 ],
190                 OUTPUT_CLUSTERS: [Time.cluster_id, Ota.cluster_id],
191             }
192         },
193     }
194 
195     replacement = {
196         ENDPOINTS: {
197             1: {
198                 DEVICE_TYPE: zha.DeviceType.ON_OFF_LIGHT,
199                 INPUT_CLUSTERS: [
200                     Basic.cluster_id,
201                     Groups.cluster_id,
202                     Scenes.cluster_id,
203                     TuyaManufacturerClusterOnOff,
204                     TuyaOnOff,
205                 ],
206                 OUTPUT_CLUSTERS: [Time.cluster_id, Ota.cluster_id],
207             },
208             2: {
209                 PROFILE_ID: zha.PROFILE_ID,
210                 DEVICE_TYPE: zha.DeviceType.ON_OFF_LIGHT,
211                 INPUT_CLUSTERS: [
212                     TuyaOnOff,
213                 ],
214                 OUTPUT_CLUSTERS: [],
215             },
216             3: {
217                 PROFILE_ID: zha.PROFILE_ID,
218                 DEVICE_TYPE: zha.DeviceType.ON_OFF_LIGHT,
219                 INPUT_CLUSTERS: [
220                     TuyaOnOff,
221                 ],
222                 OUTPUT_CLUSTERS: [],
223             },
224         }
225     }
226 
227 
228 class TuyaQuadrupleSwitchTO(TuyaSwitch):
229     """Tuya quadruple channel switch time on out cluster device."""
230 
231     signature = {
232         MODELS_INFO: [
233             ("_TZE200_aqnazj70", "TS0601"),
234             ("_TZE200_1ozguk6x", "TS0601"),
235         ],
236         ENDPOINTS: {
237             1: {
238                 PROFILE_ID: zha.PROFILE_ID,
239                 DEVICE_TYPE: zha.DeviceType.SMART_PLUG,
240                 INPUT_CLUSTERS: [
241                     Basic.cluster_id,
242                     Groups.cluster_id,
243                     Scenes.cluster_id,
244                     TuyaManufCluster.cluster_id,
245                 ],
246                 OUTPUT_CLUSTERS: [Time.cluster_id, Ota.cluster_id],
247             }
248         },
249     }
250 
251     replacement = {
252         ENDPOINTS: {
253             1: {
254                 DEVICE_TYPE: zha.DeviceType.ON_OFF_LIGHT,
255                 INPUT_CLUSTERS: [
256                     Basic.cluster_id,
257                     Groups.cluster_id,
258                     Scenes.cluster_id,
259                     TuyaManufacturerClusterOnOff,
260                     TuyaOnOff,
261                 ],
262                 OUTPUT_CLUSTERS: [Time.cluster_id, Ota.cluster_id],
263             },
264             2: {
265                 PROFILE_ID: zha.PROFILE_ID,
266                 DEVICE_TYPE: zha.DeviceType.ON_OFF_LIGHT,
267                 INPUT_CLUSTERS: [
268                     TuyaOnOff,
269                 ],
270                 OUTPUT_CLUSTERS: [],
271             },
272             3: {
273                 PROFILE_ID: zha.PROFILE_ID,
274                 DEVICE_TYPE: zha.DeviceType.ON_OFF_LIGHT,
275                 INPUT_CLUSTERS: [
276                     TuyaOnOff,
277                 ],
278                 OUTPUT_CLUSTERS: [],
279             },
280             4: {
281                 PROFILE_ID: zha.PROFILE_ID,
282                 DEVICE_TYPE: zha.DeviceType.ON_OFF_LIGHT,
283                 INPUT_CLUSTERS: [
284                     TuyaOnOff,
285                 ],
286                 OUTPUT_CLUSTERS: [],
287             },
288         }
289     }
290
```
--- END FILES ---

Please first localize the bug based on the issue statement, and then generate a patch according to the `git diff` format fenced by three backticks.

Here is an example:

```diff
diff --git a/examples/server_async.py b/examples/server_async.py
--- a/examples/server_async.py
+++ b/examples/server_async.py
@@ -313,4 +313,4 @@
 
 
 if __name__ == "__main__":
-    asyncio.run(run_async_server("."), debug=True)
+    asyncio.run(run_async_server(), debug=True)
diff --git a/examples/server_sync.py b/examples/server_sync.py
--- a/examples/server_sync.py
+++ b/examples/server_sync.py
@@ -313,5 +313,5 @@
 
 
 if __name__ == "__main__":
-    server = run_sync_server(".")
+    server = run_sync_server()
     server.shutdown()

```

diff --git a/zhaquirks/tuya/ts0601_switch.py b/zhaquirks/tuya/ts0601_switch.py
--- a/zhaquirks/tuya/ts0601_switch.py
+++ b/zhaquirks/tuya/ts0601_switch.py
@@ -81,6 +81,7 @@
             ("_TZE200_vhy3iakz", "TS0601"),  # ¿1 or 4 gangs?
             ("_TZ3000_uim07oem", "TS0601"),  # ¿1 or 4 gangs?
             ("_TZE200_wfxuhoea", "TS0601"),
+            ("_TZE200_tviaymwx", "TS0601"),
         ],
         ENDPOINTS: {
             1: {

{"golden_diff": "diff --git a/zhaquirks/tuya/ts0601_switch.py b/zhaquirks/tuya/ts0601_switch.py\n--- a/zhaquirks/tuya/ts0601_switch.py\n+++ b/zhaquirks/tuya/ts0601_switch.py\n@@ -81,6 +81,7 @@\n             (\"_TZE200_vhy3iakz\", \"TS0601\"),  # \u00bf1 or 4 gangs?\n             (\"_TZ3000_uim07oem\", \"TS0601\"),  # \u00bf1 or 4 gangs?\n             (\"_TZE200_wfxuhoea\", \"TS0601\"),\n+            (\"_TZE200_tviaymwx\", \"TS0601\"),\n         ],\n         ENDPOINTS: {\n             1: {\n", "issue": "[Device Support Request]\n**Is your feature request related to a problem? Please describe.**\r\n\r\nWhen my zigbee is discovered (_TZE200_tviaymwx ) by the Zigbee Home Automation integration Home Assistant, it's not properly recognized. Is not using the propew Quirk (TuyaSingleSwitchTO) and thus, is nos showing the proper controls. This is a new variant of the same 1 gang switch.\r\n\r\n![image](https://user-images.githubusercontent.com/16512477/154132535-155d3af9-ef5d-4619-ad5e-28887e000553.png)\r\n\r\n\r\n**Describe the solution you'd like**\r\nI like the device to be discovered properly and with the proper quirkc attached like this other one\r\n\r\n![image](https://user-images.githubusercontent.com/16512477/154132803-59650e5e-3210-4db2-9eda-08c502f48a4c.png)\r\n\r\n\r\n**Device signature - this can be acquired by removing the device from ZHA and pairing it again from the add devices screen. Be sure to add the entire content of the log panel after pairing the device to a code block below this line.**\r\n\r\n```\r\n{\r\n  \"node_descriptor\": \"NodeDescriptor(logical_type=<LogicalType.EndDevice: 2>, complex_descriptor_available=0, user_descriptor_available=0, reserved=0, aps_flags=0, frequency_band=<FrequencyBand.Freq2400MHz: 8>, mac_capability_flags=<MACCapabilityFlags.AllocateAddress: 128>, manufacturer_code=4098, maximum_buffer_size=82, maximum_incoming_transfer_size=82, server_mask=11264, maximum_outgoing_transfer_size=82, descriptor_capability_field=<DescriptorCapability.NONE: 0>, *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)\",\r\n  \"endpoints\": {\r\n    \"1\": {\r\n      \"profile_id\": 260,\r\n      \"device_type\": \"0x0051\",\r\n      \"in_clusters\": [\r\n        \"0x0000\",\r\n        \"0x0004\",\r\n        \"0x0005\",\r\n        \"0xef00\"\r\n      ],\r\n      \"out_clusters\": [\r\n        \"0x000a\",\r\n        \"0x0019\"\r\n      ]\r\n    }\r\n  },\r\n  \"manufacturer\": \"_TZE200_tviaymwx\",\r\n  \"model\": \"TS0601\",\r\n  \"class\": \"zigpy.device.Device\"\r\n}\r\n```\r\n\r\n**Additional context**\r\nAdd any other context or screenshots about the feature request here.\r\n\n", "before_files": [{"content": "\"\"\"Tuya DP based switches.\"\"\"\nfrom zigpy.profiles import zha\nfrom zigpy.zcl.clusters.general import Basic, Groups, Ota, Scenes, Time\n\nfrom zhaquirks.const import (\n    DEVICE_TYPE,\n    ENDPOINTS,\n    INPUT_CLUSTERS,\n    MODELS_INFO,\n    OUTPUT_CLUSTERS,\n    PROFILE_ID,\n)\nfrom zhaquirks.tuya import (\n    TuyaManufacturerClusterOnOff,\n    TuyaManufCluster,\n    TuyaOnOff,\n    TuyaSwitch,\n)\n\n\nclass TuyaSingleSwitchTI(TuyaSwitch):\n    \"\"\"Tuya single channel switch time on in cluster device.\"\"\"\n\n    signature = {\n        # \"node_descriptor\": \"<NodeDescriptor byte1=1 byte2=64 mac_capability_flags=142 manufacturer_code=4098\n        #                       maximum_buffer_size=82 maximum_incoming_transfer_size=82 server_mask=11264\n        #                       maximum_outgoing_transfer_size=82 descriptor_capability_field=0>\",\n        # device_version=1\n        # input_clusters=[0x0000,0x0004, 0x0005,0x000a, 0xef00]\n        # output_clusters=[0x0019]\n        # <SimpleDescriptor endpoint=1 profile=260 device_type=81 device_version=1 input_clusters=[0, 4, 5, 10, 61184] output_clusters=[25]>\n        MODELS_INFO: [(\"_TZE200_7tdtqgwv\", \"TS0601\")],\n        ENDPOINTS: {\n            1: {\n                PROFILE_ID: zha.PROFILE_ID,\n                DEVICE_TYPE: zha.DeviceType.SMART_PLUG,\n                INPUT_CLUSTERS: [\n                    Basic.cluster_id,\n                    Groups.cluster_id,\n                    Scenes.cluster_id,\n                    Time.cluster_id,\n                    TuyaManufCluster.cluster_id,\n                ],\n                OUTPUT_CLUSTERS: [Ota.cluster_id],\n            }\n        },\n    }\n\n    replacement = {\n        ENDPOINTS: {\n            1: {\n                DEVICE_TYPE: zha.DeviceType.ON_OFF_LIGHT,\n                INPUT_CLUSTERS: [\n                    Basic.cluster_id,\n                    Time.cluster_id,\n                    Groups.cluster_id,\n                    Scenes.cluster_id,\n                    TuyaManufacturerClusterOnOff,\n                    TuyaOnOff,\n                ],\n                OUTPUT_CLUSTERS: [Ota.cluster_id],\n            }\n        }\n    }\n\n\nclass TuyaSingleSwitchTO(TuyaSwitch):\n    \"\"\"Tuya single channel switch time on out cluster device.\"\"\"\n\n    signature = {\n        # \"node_descriptor\": \"<NodeDescriptor byte1=1 byte2=64 mac_capability_flags=142 manufacturer_code=4098\n        #                       maximum_buffer_size=82 maximum_incoming_transfer_size=82 server_mask=11264\n        #                       maximum_outgoing_transfer_size=82 descriptor_capability_field=0>\",\n        # device_version=1\n        # input_clusters=[0x0000, 0x0004, 0x0005, 0xef00]\n        # output_clusters=[0x000a, 0x0019]\n        # <SimpleDescriptor endpoint=1 profile=260 device_type=51 device_version=1 input_clusters=[0, 4, 5, 61184] output_clusters=[10, 25]>\n        MODELS_INFO: [\n            (\"_TZE200_amp6tsvy\", \"TS0601\"),\n            (\"_TZE200_oisqyl4o\", \"TS0601\"),\n            (\"_TZE200_vhy3iakz\", \"TS0601\"),  # \u00bf1 or 4 gangs?\n            (\"_TZ3000_uim07oem\", \"TS0601\"),  # \u00bf1 or 4 gangs?\n            (\"_TZE200_wfxuhoea\", \"TS0601\"),\n        ],\n        ENDPOINTS: {\n            1: {\n                PROFILE_ID: zha.PROFILE_ID,\n                DEVICE_TYPE: zha.DeviceType.SMART_PLUG,\n                INPUT_CLUSTERS: [\n                    Basic.cluster_id,\n                    Groups.cluster_id,\n                    Scenes.cluster_id,\n                    TuyaManufCluster.cluster_id,\n                ],\n                OUTPUT_CLUSTERS: [Time.cluster_id, Ota.cluster_id],\n            }\n        },\n    }\n\n    replacement = {\n        ENDPOINTS: {\n            1: {\n                DEVICE_TYPE: zha.DeviceType.ON_OFF_LIGHT,\n                INPUT_CLUSTERS: [\n                    Basic.cluster_id,\n                    Groups.cluster_id,\n                    Scenes.cluster_id,\n                    TuyaManufacturerClusterOnOff,\n                    TuyaOnOff,\n                ],\n                OUTPUT_CLUSTERS: [Time.cluster_id, Ota.cluster_id],\n            }\n        }\n    }\n\n\nclass TuyaDoubleSwitchTO(TuyaSwitch):\n    \"\"\"Tuya double channel switch time on out cluster device.\"\"\"\n\n    signature = {\n        # \"node_descriptor\": \"<NodeDescriptor byte1=1 byte2=64 mac_capability_flags=142 manufacturer_code=4098\n        #                       maximum_buffer_size=82 maximum_incoming_transfer_size=82 server_mask=11264\n        #                       maximum_outgoing_transfer_size=82 descriptor_capability_field=0>\",\n        # device_version=1\n        # input_clusters=[0x0000, 0x0004, 0x0005, 0xef00]\n        # output_clusters=[0x000a, 0x0019]\n        # <SimpleDescriptor endpoint=1 profile=260 device_type=51 device_version=1 input_clusters=[0, 4, 5, 61184] output_clusters=[10, 25]>\n        MODELS_INFO: [\n            (\"_TZE200_g1ib5ldv\", \"TS0601\"),\n            (\"_TZE200_wunufsil\", \"TS0601\"),\n        ],\n        ENDPOINTS: {\n            1: {\n                PROFILE_ID: zha.PROFILE_ID,\n                DEVICE_TYPE: zha.DeviceType.SMART_PLUG,\n                INPUT_CLUSTERS: [\n                    Basic.cluster_id,\n                    Groups.cluster_id,\n                    Scenes.cluster_id,\n                    TuyaManufCluster.cluster_id,\n                ],\n                OUTPUT_CLUSTERS: [Time.cluster_id, Ota.cluster_id],\n            }\n        },\n    }\n\n    replacement = {\n        ENDPOINTS: {\n            1: {\n                DEVICE_TYPE: zha.DeviceType.ON_OFF_LIGHT,\n                INPUT_CLUSTERS: [\n                    Basic.cluster_id,\n                    Groups.cluster_id,\n                    Scenes.cluster_id,\n                    TuyaManufacturerClusterOnOff,\n                    TuyaOnOff,\n                ],\n                OUTPUT_CLUSTERS: [Time.cluster_id, Ota.cluster_id],\n            },\n            2: {\n                PROFILE_ID: zha.PROFILE_ID,\n                DEVICE_TYPE: zha.DeviceType.ON_OFF_LIGHT,\n                INPUT_CLUSTERS: [\n                    TuyaOnOff,\n                ],\n                OUTPUT_CLUSTERS: [],\n            },\n        }\n    }\n\n\nclass TuyaTripleSwitchTO(TuyaSwitch):\n    \"\"\"Tuya triple channel switch time on out cluster device.\"\"\"\n\n    signature = {\n        MODELS_INFO: [\n            # (\"_TZE200_kyfqmmyl\", \"TS0601\"),  ## candidate reported in #716\n            (\"_TZE200_tz32mtza\", \"TS0601\"),\n        ],\n        ENDPOINTS: {\n            1: {\n                PROFILE_ID: zha.PROFILE_ID,\n                DEVICE_TYPE: zha.DeviceType.SMART_PLUG,\n                INPUT_CLUSTERS: [\n                    Basic.cluster_id,\n                    Groups.cluster_id,\n                    Scenes.cluster_id,\n                    TuyaManufCluster.cluster_id,\n                ],\n                OUTPUT_CLUSTERS: [Time.cluster_id, Ota.cluster_id],\n            }\n        },\n    }\n\n    replacement = {\n        ENDPOINTS: {\n            1: {\n                DEVICE_TYPE: zha.DeviceType.ON_OFF_LIGHT,\n                INPUT_CLUSTERS: [\n                    Basic.cluster_id,\n                    Groups.cluster_id,\n                    Scenes.cluster_id,\n                    TuyaManufacturerClusterOnOff,\n                    TuyaOnOff,\n                ],\n                OUTPUT_CLUSTERS: [Time.cluster_id, Ota.cluster_id],\n            },\n            2: {\n                PROFILE_ID: zha.PROFILE_ID,\n                DEVICE_TYPE: zha.DeviceType.ON_OFF_LIGHT,\n                INPUT_CLUSTERS: [\n                    TuyaOnOff,\n                ],\n                OUTPUT_CLUSTERS: [],\n            },\n            3: {\n                PROFILE_ID: zha.PROFILE_ID,\n                DEVICE_TYPE: zha.DeviceType.ON_OFF_LIGHT,\n                INPUT_CLUSTERS: [\n                    TuyaOnOff,\n                ],\n                OUTPUT_CLUSTERS: [],\n            },\n        }\n    }\n\n\nclass TuyaQuadrupleSwitchTO(TuyaSwitch):\n    \"\"\"Tuya quadruple channel switch time on out cluster device.\"\"\"\n\n    signature = {\n        MODELS_INFO: [\n            (\"_TZE200_aqnazj70\", \"TS0601\"),\n            (\"_TZE200_1ozguk6x\", \"TS0601\"),\n        ],\n        ENDPOINTS: {\n            1: {\n                PROFILE_ID: zha.PROFILE_ID,\n                DEVICE_TYPE: zha.DeviceType.SMART_PLUG,\n                INPUT_CLUSTERS: [\n                    Basic.cluster_id,\n                    Groups.cluster_id,\n                    Scenes.cluster_id,\n                    TuyaManufCluster.cluster_id,\n                ],\n                OUTPUT_CLUSTERS: [Time.cluster_id, Ota.cluster_id],\n            }\n        },\n    }\n\n    replacement = {\n        ENDPOINTS: {\n            1: {\n                DEVICE_TYPE: zha.DeviceType.ON_OFF_LIGHT,\n                INPUT_CLUSTERS: [\n                    Basic.cluster_id,\n                    Groups.cluster_id,\n                    Scenes.cluster_id,\n                    TuyaManufacturerClusterOnOff,\n                    TuyaOnOff,\n                ],\n                OUTPUT_CLUSTERS: [Time.cluster_id, Ota.cluster_id],\n            },\n            2: {\n                PROFILE_ID: zha.PROFILE_ID,\n                DEVICE_TYPE: zha.DeviceType.ON_OFF_LIGHT,\n                INPUT_CLUSTERS: [\n                    TuyaOnOff,\n                ],\n                OUTPUT_CLUSTERS: [],\n            },\n            3: {\n                PROFILE_ID: zha.PROFILE_ID,\n                DEVICE_TYPE: zha.DeviceType.ON_OFF_LIGHT,\n                INPUT_CLUSTERS: [\n                    TuyaOnOff,\n                ],\n                OUTPUT_CLUSTERS: [],\n            },\n            4: {\n                PROFILE_ID: zha.PROFILE_ID,\n                DEVICE_TYPE: zha.DeviceType.ON_OFF_LIGHT,\n                INPUT_CLUSTERS: [\n                    TuyaOnOff,\n                ],\n                OUTPUT_CLUSTERS: [],\n            },\n        }\n    }\n", "path": "zhaquirks/tuya/ts0601_switch.py"}], "after_files": [{"content": "\"\"\"Tuya DP based switches.\"\"\"\nfrom zigpy.profiles import zha\nfrom zigpy.zcl.clusters.general import Basic, Groups, Ota, Scenes, Time\n\nfrom zhaquirks.const import (\n    DEVICE_TYPE,\n    ENDPOINTS,\n    INPUT_CLUSTERS,\n    MODELS_INFO,\n    OUTPUT_CLUSTERS,\n    PROFILE_ID,\n)\nfrom zhaquirks.tuya import (\n    TuyaManufacturerClusterOnOff,\n    TuyaManufCluster,\n    TuyaOnOff,\n    TuyaSwitch,\n)\n\n\nclass TuyaSingleSwitchTI(TuyaSwitch):\n    \"\"\"Tuya single channel switch time on in cluster device.\"\"\"\n\n    signature = {\n        # \"node_descriptor\": \"<NodeDescriptor byte1=1 byte2=64 mac_capability_flags=142 manufacturer_code=4098\n        #                       maximum_buffer_size=82 maximum_incoming_transfer_size=82 server_mask=11264\n        #                       maximum_outgoing_transfer_size=82 descriptor_capability_field=0>\",\n        # device_version=1\n        # input_clusters=[0x0000,0x0004, 0x0005,0x000a, 0xef00]\n        # output_clusters=[0x0019]\n        # <SimpleDescriptor endpoint=1 profile=260 device_type=81 device_version=1 input_clusters=[0, 4, 5, 10, 61184] output_clusters=[25]>\n        MODELS_INFO: [(\"_TZE200_7tdtqgwv\", \"TS0601\")],\n        ENDPOINTS: {\n            1: {\n                PROFILE_ID: zha.PROFILE_ID,\n                DEVICE_TYPE: zha.DeviceType.SMART_PLUG,\n                INPUT_CLUSTERS: [\n                    Basic.cluster_id,\n                    Groups.cluster_id,\n                    Scenes.cluster_id,\n                    Time.cluster_id,\n                    TuyaManufCluster.cluster_id,\n                ],\n                OUTPUT_CLUSTERS: [Ota.cluster_id],\n            }\n        },\n    }\n\n    replacement = {\n        ENDPOINTS: {\n            1: {\n                DEVICE_TYPE: zha.DeviceType.ON_OFF_LIGHT,\n                INPUT_CLUSTERS: [\n                    Basic.cluster_id,\n                    Time.cluster_id,\n                    Groups.cluster_id,\n                    Scenes.cluster_id,\n                    TuyaManufacturerClusterOnOff,\n                    TuyaOnOff,\n                ],\n                OUTPUT_CLUSTERS: [Ota.cluster_id],\n            }\n        }\n    }\n\n\nclass TuyaSingleSwitchTO(TuyaSwitch):\n    \"\"\"Tuya single channel switch time on out cluster device.\"\"\"\n\n    signature = {\n        # \"node_descriptor\": \"<NodeDescriptor byte1=1 byte2=64 mac_capability_flags=142 manufacturer_code=4098\n        #                       maximum_buffer_size=82 maximum_incoming_transfer_size=82 server_mask=11264\n        #                       maximum_outgoing_transfer_size=82 descriptor_capability_field=0>\",\n        # device_version=1\n        # input_clusters=[0x0000, 0x0004, 0x0005, 0xef00]\n        # output_clusters=[0x000a, 0x0019]\n        # <SimpleDescriptor endpoint=1 profile=260 device_type=51 device_version=1 input_clusters=[0, 4, 5, 61184] output_clusters=[10, 25]>\n        MODELS_INFO: [\n            (\"_TZE200_amp6tsvy\", \"TS0601\"),\n            (\"_TZE200_oisqyl4o\", \"TS0601\"),\n            (\"_TZE200_vhy3iakz\", \"TS0601\"),  # \u00bf1 or 4 gangs?\n            (\"_TZ3000_uim07oem\", \"TS0601\"),  # \u00bf1 or 4 gangs?\n            (\"_TZE200_wfxuhoea\", \"TS0601\"),\n            (\"_TZE200_tviaymwx\", \"TS0601\"),\n        ],\n        ENDPOINTS: {\n            1: {\n                PROFILE_ID: zha.PROFILE_ID,\n                DEVICE_TYPE: zha.DeviceType.SMART_PLUG,\n                INPUT_CLUSTERS: [\n                    Basic.cluster_id,\n                    Groups.cluster_id,\n                    Scenes.cluster_id,\n                    TuyaManufCluster.cluster_id,\n                ],\n                OUTPUT_CLUSTERS: [Time.cluster_id, Ota.cluster_id],\n            }\n        },\n    }\n\n    replacement = {\n        ENDPOINTS: {\n            1: {\n                DEVICE_TYPE: zha.DeviceType.ON_OFF_LIGHT,\n                INPUT_CLUSTERS: [\n                    Basic.cluster_id,\n                    Groups.cluster_id,\n                    Scenes.cluster_id,\n                    TuyaManufacturerClusterOnOff,\n                    TuyaOnOff,\n                ],\n                OUTPUT_CLUSTERS: [Time.cluster_id, Ota.cluster_id],\n            }\n        }\n    }\n\n\nclass TuyaDoubleSwitchTO(TuyaSwitch):\n    \"\"\"Tuya double channel switch time on out cluster device.\"\"\"\n\n    signature = {\n        # \"node_descriptor\": \"<NodeDescriptor byte1=1 byte2=64 mac_capability_flags=142 manufacturer_code=4098\n        #                       maximum_buffer_size=82 maximum_incoming_transfer_size=82 server_mask=11264\n        #                       maximum_outgoing_transfer_size=82 descriptor_capability_field=0>\",\n        # device_version=1\n        # input_clusters=[0x0000, 0x0004, 0x0005, 0xef00]\n        # output_clusters=[0x000a, 0x0019]\n        # <SimpleDescriptor endpoint=1 profile=260 device_type=51 device_version=1 input_clusters=[0, 4, 5, 61184] output_clusters=[10, 25]>\n        MODELS_INFO: [\n            (\"_TZE200_g1ib5ldv\", \"TS0601\"),\n            (\"_TZE200_wunufsil\", \"TS0601\"),\n        ],\n        ENDPOINTS: {\n            1: {\n                PROFILE_ID: zha.PROFILE_ID,\n                DEVICE_TYPE: zha.DeviceType.SMART_PLUG,\n                INPUT_CLUSTERS: [\n                    Basic.cluster_id,\n                    Groups.cluster_id,\n                    Scenes.cluster_id,\n                    TuyaManufCluster.cluster_id,\n                ],\n                OUTPUT_CLUSTERS: [Time.cluster_id, Ota.cluster_id],\n            }\n        },\n    }\n\n    replacement = {\n        ENDPOINTS: {\n            1: {\n                DEVICE_TYPE: zha.DeviceType.ON_OFF_LIGHT,\n                INPUT_CLUSTERS: [\n                    Basic.cluster_id,\n                    Groups.cluster_id,\n                    Scenes.cluster_id,\n                    TuyaManufacturerClusterOnOff,\n                    TuyaOnOff,\n                ],\n                OUTPUT_CLUSTERS: [Time.cluster_id, Ota.cluster_id],\n            },\n            2: {\n                PROFILE_ID: zha.PROFILE_ID,\n                DEVICE_TYPE: zha.DeviceType.ON_OFF_LIGHT,\n                INPUT_CLUSTERS: [\n                    TuyaOnOff,\n                ],\n                OUTPUT_CLUSTERS: [],\n            },\n        }\n    }\n\n\nclass TuyaTripleSwitchTO(TuyaSwitch):\n    \"\"\"Tuya triple channel switch time on out cluster device.\"\"\"\n\n    signature = {\n        MODELS_INFO: [\n            # (\"_TZE200_kyfqmmyl\", \"TS0601\"),  ## candidate reported in #716\n            (\"_TZE200_tz32mtza\", \"TS0601\"),\n        ],\n        ENDPOINTS: {\n            1: {\n                PROFILE_ID: zha.PROFILE_ID,\n                DEVICE_TYPE: zha.DeviceType.SMART_PLUG,\n                INPUT_CLUSTERS: [\n                    Basic.cluster_id,\n                    Groups.cluster_id,\n                    Scenes.cluster_id,\n                    TuyaManufCluster.cluster_id,\n                ],\n                OUTPUT_CLUSTERS: [Time.cluster_id, Ota.cluster_id],\n            }\n        },\n    }\n\n    replacement = {\n        ENDPOINTS: {\n            1: {\n                DEVICE_TYPE: zha.DeviceType.ON_OFF_LIGHT,\n                INPUT_CLUSTERS: [\n                    Basic.cluster_id,\n                    Groups.cluster_id,\n                    Scenes.cluster_id,\n                    TuyaManufacturerClusterOnOff,\n                    TuyaOnOff,\n                ],\n                OUTPUT_CLUSTERS: [Time.cluster_id, Ota.cluster_id],\n            },\n            2: {\n                PROFILE_ID: zha.PROFILE_ID,\n                DEVICE_TYPE: zha.DeviceType.ON_OFF_LIGHT,\n                INPUT_CLUSTERS: [\n                    TuyaOnOff,\n                ],\n                OUTPUT_CLUSTERS: [],\n            },\n            3: {\n                PROFILE_ID: zha.PROFILE_ID,\n                DEVICE_TYPE: zha.DeviceType.ON_OFF_LIGHT,\n                INPUT_CLUSTERS: [\n                    TuyaOnOff,\n                ],\n                OUTPUT_CLUSTERS: [],\n            },\n        }\n    }\n\n\nclass TuyaQuadrupleSwitchTO(TuyaSwitch):\n    \"\"\"Tuya quadruple channel switch time on out cluster device.\"\"\"\n\n    signature = {\n        MODELS_INFO: [\n            (\"_TZE200_aqnazj70\", \"TS0601\"),\n            (\"_TZE200_1ozguk6x\", \"TS0601\"),\n        ],\n        ENDPOINTS: {\n            1: {\n                PROFILE_ID: zha.PROFILE_ID,\n                DEVICE_TYPE: zha.DeviceType.SMART_PLUG,\n                INPUT_CLUSTERS: [\n                    Basic.cluster_id,\n                    Groups.cluster_id,\n                    Scenes.cluster_id,\n                    TuyaManufCluster.cluster_id,\n                ],\n                OUTPUT_CLUSTERS: [Time.cluster_id, Ota.cluster_id],\n            }\n        },\n    }\n\n    replacement = {\n        ENDPOINTS: {\n            1: {\n                DEVICE_TYPE: zha.DeviceType.ON_OFF_LIGHT,\n                INPUT_CLUSTERS: [\n                    Basic.cluster_id,\n                    Groups.cluster_id,\n                    Scenes.cluster_id,\n                    TuyaManufacturerClusterOnOff,\n                    TuyaOnOff,\n                ],\n                OUTPUT_CLUSTERS: [Time.cluster_id, Ota.cluster_id],\n            },\n            2: {\n                PROFILE_ID: zha.PROFILE_ID,\n                DEVICE_TYPE: zha.DeviceType.ON_OFF_LIGHT,\n                INPUT_CLUSTERS: [\n                    TuyaOnOff,\n                ],\n                OUTPUT_CLUSTERS: [],\n            },\n            3: {\n                PROFILE_ID: zha.PROFILE_ID,\n                DEVICE_TYPE: zha.DeviceType.ON_OFF_LIGHT,\n                INPUT_CLUSTERS: [\n                    TuyaOnOff,\n                ],\n                OUTPUT_CLUSTERS: [],\n            },\n            4: {\n                PROFILE_ID: zha.PROFILE_ID,\n                DEVICE_TYPE: zha.DeviceType.ON_OFF_LIGHT,\n                INPUT_CLUSTERS: [\n                    TuyaOnOff,\n                ],\n                OUTPUT_CLUSTERS: [],\n            },\n        }\n    }\n", "path": "zhaquirks/tuya/ts0601_switch.py"}]}