Zemismart Zigbee 1/2/3/4 gang light switches

@ADDs Is your device is a 3 gang switch?
This driver has a fingerprint for the 2 gang version, if you confirm I will add your 3 gang switch in the driver.

What happens when you press the Initialize button? Do you have 3 child devices created?

Please make sure the Debug option is turned on, then press the on/off buttons on n the device web page and if it doesn’t work, copy and paste the debug logs.

@kkossev Thanks for the quick response seems like I’ve got it working now I had to remove the device and do a reset on it then pair it again and it paired straight to your driver this time.

Yes it is a three gang Zigbee module it dose initialise and creates 3 child devices.

Thanks again for your help is there anything else you’d like to know.

1 Like

Hi. I just tried again the last indicated driver. Now it works perfectly, thank you very much.

The power on state function is preset to off. In this state it runs correctly. But even though I try to change it (ON/Latest) in the dropdown button, and click save, it shows up as "OFF" again.

1 Like

Currently, the Power On parameter is implemented as a Command in this driver (not as a Preference parameter). So yes, it may be confusing because the HE drivers commands parameters lists always start with the first parameter when the web page is refreshed, no matter what the actual state is.. To avoid confusion I have changed the command like this, so it should be more intuitive now that you should first make a choice, and then pres the "Power On State" button
image

If the power on behavior change command was confirmed by the device, now you should see also a confirmation on the parent device log page:

These changes are made in the driver development branch, the second link in this post. ( driver ver. 0.2.6 )

If it is possible with your setup. can you please try again changing the power on mode with your wall switch? ( its not very easy to test, as you need to turn off the circuit breaker that powers the lights switch ).

I think I understand now what you say. However, I couldn't get it to work. I'm not sure if I did the test anyway even though it didn't reflect what I selected. I'll try again Asap and commented but I don't promise it will be in 2-3 days. I understand that you have to test with several devices, unfortunately I don't know how to program with this language although I would like to learn. I am working on yours with a lux sensor similar to one of your drivers that does not work correctly for me either.

No rush for tests, the power on behavior is not the most important feature, just an opinion that is nice to have IMO.

On the Lux sensor issue - you can post your device details in this thread,

I check it now. It works great (ON/OFF/Latest).

Thanks a lot.

1 Like

I’ve noticed the device(tuya ts0013) doesn’t refresh status when switched manually anybody else had this problem?

I’ve created a 30second rule to refresh for now.

Please turn the Debug logs on and copy/paste the logs when the switches (1 2 and 3) are turned on/off manually.

You can use the forum editor 'Hide Details' feature (select the log lines first) :

Refreshing every 30 seconds will work but is not the best solution long term.

dev:2902022-06-04 08:08:38.940 pm debugoff()

dev:2902022-06-04 08:08:34.662 pm debugon()

dev:2902022-06-04 08:07:35.623 pm infoChild switch 01 turned off

dev:2902022-06-04 07:57:35.302 pm infoChild switch 01 turned on

dev:2902022-06-04 07:49:28.755 pm debugon()

--- Live Log Started, waiting for events ---
The switch was turn off manually almost instantly but took 10mins to show

I'll try getting the other logs just not easy in a busy house

Actually just realised device status dosnt seem to update when turn on and off on the device page but the switch dose do as asked just dosnt show the correct status still so seems as though it's not just manual.

Seems like the Debug option is not switched on.
Look at the 'Parent' device logs, you mus see something similar to this:

Summary

dev:13762022-06-04 22:30:35.963 debugTuya Switch Module TS0004 Parsed: [raw:72E70100060800001000, dni:72E7, endpoint:01, cluster:0006, size:08, attrId:0000, encoding:10, command:0A, value:00, clusterInt:6, attrInt:0]

dev:13762022-06-04 22:30:35.944 debugTuya Switch Module TS0004 Parsed: [raw:72E70100060800001000, dni:72E7, endpoint:01, cluster:0006, size:08, attrId:0000, encoding:10, command:0A, value:00, clusterInt:6, attrInt:0]

dev:13762022-06-04 22:30:34.184 debugTuya Switch Module TS0004 Parent switch on

dev:13762022-06-04 22:30:34.172 debugTuya Switch Module TS0004 Parsed: [raw:72E70300060800001001, dni:72E7, endpoint:03, cluster:0006, size:08, attrId:0000, encoding:10, command:0A, value:01, clusterInt:6, attrInt:0]

dev:13762022-06-04 22:30:28.747 debugTuya Switch Module TS0004 Parsed: [raw:72E70200060800001000, dni:72E7, endpoint:02, cluster:0006, size:08, attrId:0000, encoding:10, command:0A, value:00, clusterInt:6, attrInt:0]

dev:13762022-06-04 22:30:21.994 debugTuya Switch Module TS0004 Parent switch on

Says on the child devices page and parent that debug logs are on.

search

dev:2892022-06-04 08:20:09.180 pm debugParsed: [raw:catchall: 0104 0006 01 01 0040 00 F99F 00 00 0000 0B 01 0000, profileId:0104, clusterId:0006, clusterInt:6, sourceEndpoint:01, destinationEndpoint:01, options:0040, messageType:00, dni:F99F, isClusterSpecific:false, isManufacturerSpecific:false, manufacturerId:0000, command:0B, direction:01, data:[00, 00]]

dev:2892022-06-04 08:20:09.044 pm debugcomponentOff 289-01

dev:2892022-06-04 08:20:03.950 pm debugParsed: [raw:catchall: 0104 0006 01 01 0040 00 F99F 00 00 0000 0B 01 0100, profileId:0104, clusterId:0006, clusterInt:6, sourceEndpoint:01, destinationEndpoint:01, options:0040, messageType:00, dni:F99F, isClusterSpecific:false, isManufacturerSpecific:false, manufacturerId:0000, command:0B, direction:01, data:[01, 00]]

dev:2892022-06-04 08:20:03.672 pm debugcomponentOn 289-01

dev:2892022-06-04 08:19:51.009 pm debugParsed: [raw:catchall: 0104 0006 01 01 0040 00 F99F 00 00 0000 0B 01 0000, profileId:0104, clusterId:0006, clusterInt:6, sourceEndpoint:01, destinationEndpoint:01, options:0040, messageType:00, dni:F99F, isClusterSpecific:false, isManufacturerSpecific:false, manufacturerId:0000, command:0B, direction:01, data:[00, 00]]

dev:2892022-06-04 08:19:50.796 pm debugcomponentOff 289-01

dev:2892022-06-04 08:19:47.887 pm debugParsed: [raw:catchall: 0104 0006 01 01 0040 00 F99F 00 00 0000 0B 01 0100, profileId:0104, clusterId:0006, clusterInt:6, sourceEndpoint:01, destinationEndpoint:01, options:0040, messageType:00, dni:F99F, isClusterSpecific:false, isManufacturerSpecific:false, manufacturerId:0000, command:0B, direction:01, data:[01, 00]]

dev:2892022-06-04 08:19:47.608 pm debugcomponentOn 289-01

dev:2892022-06-04 08:19:28.598 pm debugParsed: [raw:catchall: 0104 0006 03 01 0040 00 F99F 00 00 0000 0B 01 0100, profileId:0104, clusterId:0006, clusterInt:6, sourceEndpoint:03, destinationEndpoint:01, options:0040, messageType:00, dni:F99F, isClusterSpecific:false, isManufacturerSpecific:false, manufacturerId:0000, command:0B, direction:01, data:[01, 00]]

dev:2892022-06-04 08:19:28.385 pm debugcomponentOn 289-03

dev:2892022-06-04 08:19:26.523 pm debugParsed: [raw:catchall: 0104 0006 03 01 0040 00 F99F 00 00 0000 0B 01 0000, profileId:0104, clusterId:0006, clusterInt:6, sourceEndpoint:03, destinationEndpoint:01, options:0040, messageType:00, dni:F99F, isClusterSpecific:false, isManufacturerSpecific:false, manufacturerId:0000, command:0B, direction:01, data:[00, 00]]

dev:2892022-06-04 08:19:26.388 pm debugcomponentOff 289-03

dev:2892022-06-04 08:19:24.447 pm debugParsed: [raw:catchall: 0104 0006 03 01 0040 00 F99F 00 00 0000 0B 01 0100, profileId:0104, clusterId:0006, clusterInt:6, sourceEndpoint:03, destinationEndpoint:01, options:0040, messageType:00, dni:F99F, isClusterSpecific:false, isManufacturerSpecific:false, manufacturerId:0000, command:0B, direction:01, data:[01, 00]]

dev:2892022-06-04 08:19:24.186 pm debugcomponentOn 289-03

dev:2892022-06-04 08:19:22.369 pm debugParsed: [raw:catchall: 0104 0006 03 01 0040 00 F99F 00 00 0000 0B 01 0000, profileId:0104, clusterId:0006, clusterInt:6, sourceEndpoint:03, destinationEndpoint:01, options:0040, messageType:00, dni:F99F, isClusterSpecific:false, isManufacturerSpecific:false, manufacturerId:0000, command:0B, direction:01, data:[00, 00]]

dev:2892022-06-04 08:19:22.241 pm debugcomponentOff 289-03

dev:2892022-06-04 08:19:20.302 pm debugParsed: [raw:catchall: 0104 0006 03 01 0040 00 F99F 00 00 0000 0B 01 0100, profileId:0104, clusterId:0006, clusterInt:6, sourceEndpoint:03, destinationEndpoint:01, options:0040, messageType:00, dni:F99F, isClusterSpecific:false, isManufacturerSpecific:false, manufacturerId:0000, command:0B, direction:01, data:[01, 00]]

dev:2892022-06-04 08:19:20.155 pm debugcomponentOn 289-03

dev:2892022-06-04 08:19:05.967 pm debugParsed: [raw:catchall: 0104 0006 03 01 0040 00 F99F 00 00 0000 0B 01 0100, profileId:0104, clusterId:0006, clusterInt:6, sourceEndpoint:03, destinationEndpoint:01, options:0040, messageType:00, dni:F99F, isClusterSpecific:false, isManufacturerSpecific:false, manufacturerId:0000, command:0B, direction:01, data:[01, 00]]

dev:2892022-06-04 08:19:05.865 pm debugcomponentOn 289-03

dev:2892022-06-04 08:19:02.121 pm debugParsed: [raw:catchall: 0104 0006 03 01 0040 00 F99F 00 00 0000 0B 01 0000, profileId:0104, clusterId:0006, clusterInt:6, sourceEndpoint:03, destinationEndpoint:01, options:0040, messageType:00, dni:F99F, isClusterSpecific:false, isManufacturerSpecific:false, manufacturerId:0000, command:0B, direction:01, data:[00, 00]]

dev:2892022-06-04 08:19:01.818 pm debugcomponentOff 289-03

dev:2892022-06-04 08:08:39.431 pm debugParsed: [raw:catchall: 0104 0006 01 01 0040 00 F99F 00 00 0000 0B 01 0000, profileId:0104, clusterId:0006, clusterInt:6, sourceEndpoint:01, destinationEndpoint:01, options:0040, messageType:00, dni:F99F, isClusterSpecific:false, isManufacturerSpecific:false, manufacturerId:0000, command:0B, direction:01, data:[00, 00]]

dev:2892022-06-04 08:08:38.946 pm debugcomponentOff 289-01

dev:2892022-06-04 08:08:35.113 pm debugParsed: [raw:catchall: 0104 0006 01 01 0040 00 F99F 00 00 0000 0B 01 0100, profileId:0104, clusterId:0006, clusterInt:6, sourceEndpoint:01, destinationEndpoint:01, options:0040, messageType:00, dni:F99F, isClusterSpecific:false, isManufacturerSpecific:false, manufacturerId:0000, command:0B, direction:01, data:[01, 00]]

dev:2892022-06-04 08:08:34.723 pm debugcomponentOn 289-01

dev:2892022-06-04 08:07:35.608 pm debugParsed: [raw:F99F0100060800001000, dni:F99F, endpoint:01, cluster:0006, size:08, attrId:0000, encoding:10, command:0A, value:00, clusterInt:6, attrInt:0]

dev:2892022-06-04 07:57:35.303 pm debugParent switch on

dev:2892022-06-04 07:57:35.289 pm debugParsed: [raw:F99F0100060800001001, dni:F99F, endpoint:01, cluster:0006, size:08, attrId:0000, encoding:10, command:0A, value:01, clusterInt:6, attrInt:0]

dev:2892022-06-04 07:49:28.936 pm debugParsed: [raw:catchall: 0104 0006 01 01 0040 00 F99F 00 00 0000 0B 01 0100, profileId:0104, clusterId:0006, clusterInt:6, sourceEndpoint:01, destinationEndpoint:01, options:0040, messageType:00, dni:F99F, isClusterSpecific:false, isManufacturerSpecific:false, manufacturerId:0000, command:0B, direction:01, data:[01, 00]]

dev:2892022-06-04 07:49:28.761 pm debugcomponentOn 289-01

dev:2892022-06-04 07:47:34.627 pm debugParsed: [raw:F99F0100060800001000, dni:F99F, endpoint:01, cluster:0006, size:08, attrId:0000, encoding:10, command:0A, value:00, clusterInt:6, attrInt:0]

dev:2892022-06-04 07:47:30.703 pm debugParsed: [raw:catchall: 0104 0006 01 01 0040 00 F99F 00 00 0000 0B 01 0000, profileId:0104, clusterId:0006, clusterInt:6, sourceEndpoint:01, destinationEndpoint:01, options:0040, messageType:00, dni:F99F, isClusterSpecific:false, isManufacturerSpecific:false, manufacturerId:0000, command:0B, direction:01, data:[00, 00]]

dev:2892022-06-04 07:47:30.427 pm debugcomponentOff 289-01

dev:2892022-06-04 07:47:08.976 pm debugParsed: [raw:catchall: 0104 0006 01 01 0040 00 F99F 00 00 0000 0B 01 0000, profileId:0104, clusterId:0006, clusterInt:6, sourceEndpoint:01, destinationEndpoint:01, options:0040, messageType:00, dni:F99F, isClusterSpecific:false, isManufacturerSpecific:false, manufacturerId:0000, command:0B, direction:01, data:[00, 00]]

dev:2892022-06-04 07:47:08.668 pm debugcomponentOff 289-01

dev:2892022-06-04 07:40:26.756 pm debugParsed: [raw:catchall: 0104 0006 01 01 0040 00 F99F 00 00 0000 0B 01 0000, profileId:0104, clusterId:0006, clusterInt:6, sourceEndpoint:01, destinationEndpoint:01, options:0040, messageType:00, dni:F99F, isClusterSpecific:false, isManufacturerSpecific:false, manufacturerId:0000, command:0B, direction:01, data:[00, 00]]

dev:2892022-06-04 07:40:26.580 pm debugcomponentOff 289-01

dev:2892022-06-04 07:39:30.357 pm debugParent switch on

dev:2892022-06-04 07:39:30.352 pm debugParsed: [raw:F99F0300060A00001000, dni:F99F, endpoint:03, cluster:0006, size:0A, attrId:0000, encoding:10, command:01, value:00, clusterInt:6, attrInt:0]

dev:2892022-06-04 07:39:30.346 pm debugParent switch on

dev:2892022-06-04 07:39:30.340 pm debugParsed: [raw:F99F0200060A00001001, dni:F99F, endpoint:02, cluster:0006, size:0A, attrId:0000, encoding:10, command:01, value:01, clusterInt:6, attrInt:0]

dev:2892022-06-04 07:39:30.336 pm debugParsed: [raw:F99F0100060A00001001, dni:F99F, endpoint:01, cluster:0006, size:0A, attrId:0000, encoding:10, command:01, value:01, clusterInt:6, attrInt:0]

dev:2892022-06-04 07:39:30.084 pm debugrefreshing

dev:2892022-06-04 07:39:00.238 pm debugParent switch on

dev:2892022-06-04 07:39:00.238 pm debugParent switch on

dev:2892022-06-04 07:39:00.232 pm debugParsed: [raw:F99F0300060A00001000, dni:F99F, endpoint:03, cluster:0006, size:0A, attrId:0000, encoding:10, command:01, value:00, clusterInt:6, attrInt:0]

1 Like

Thanks, I have the logs data now, it should help to find where the problem is.

1 Like

@ADDs can you try the fix in the new version 0.2.7 (the second link in this post) ?

@kkossev I uploaded the driver still dosnt seem to have made any difference.

Is it this version ( lines 31 and 32 in the code) ?

def version() { "0.2.7" }
def timeStamp() {"2022/06/05 12:15 AM"}

Yes it’s that one.

What was found in your previous logs was that this device sends the response to On/Off commands from HE using a Zigbee command that was not processed by the previous versions of this driver. So when using version 0.2.7 the on/off status of the 3 gangs should be reflected in HE, but obviously there is also something else that we don't know.

The only thing that comes in my mind for now is to completely remove the device from HE, and then re-pair it as a new device. Some Tuya devices require that they receive the specific initialization sequence exactly at the time of the pairing, simply pressing Initialize or Configure button does not work.

Thank you for the tests, if I find something more for this device I will let you know.

I tried deleting as you said and repaired the device but that didn't work at all only showed 1 child device and couldn't switch anything on or off I'm afraid, I couldn't even delete the device after I had to change the device handler to something else before it would let me delete it otherwise would just hang on the removal page.

I know your trying to help and I appreciate it I'm sorry this isn't working :weary:

1 Like