[RELEASE] Tuya Scene Switch TS004F driver (w/ healthStatus)

Actually, I did notice high connectivity issues.

Summary - apart from bedroom 3, I have experienced missed activation with the buttons in the screenshot below

It is difficult to say whether the number of the Zigbee network rejoin events is too high or is normal...
This driver is missing a command to reset the statistics, it may be a good idea to add such a function. Probably when the 'Configure' button is clicked.

1 Like

Yes, true - a reset stat function will be useful.
These button controllers have been working fine since the last battery change, so not sure when the rejoin events occurred.

My Zigbee network

1 Like

I have changed the driver to Zigbee button dimmer for the living room - working fine so far, will monitor. Thanks

1 Like

I am using the RTT (round-trip tiime) measurements as an indicator of the hub Zigbee network health and latency .

The graph below was posted 6 months ago, during the Beta testing of the first Hubitat Matter versions :


Pings screenshot

I use a very simple RM5 rule to ping the plug every 15 seconds :

And then WebCoRE graphs and LTS (Long Term Storage)

1 Like

Dev. branch version 2.7.2 2024/05/06 12:49 PM clears the statistics when the Configure button is pressed. (the driver version is refreshed in the State Variables when something is received form the device, and the browser page is refreshed).

1 Like

@iEnam I think that I may have found the problem - it may be a 2-years old bug... : (

Update to the new dev. branch version, 2.7.2 2024-05-06 timeStamp '2024/05/06 11:24 PM'

  • bug fix: TS0044 _TZ3000_vp6clf9d _TZ3000_ur5fpg7p _TZ3000_wkai4ga5 needed to be pushed twice to activate a button;
  • Configure button will reset the statistics;

Only these 3 TS0044 device manufacturers are affected, this explains why I can not replicate it with my devices.

Please test and let me know if the problem with the missing event has gone.


Great job, no issues experienced with the new dev version!


1 Like

Thanks for this excellent device driver. Works nicely for my MOES ZigBee 12 Scene Switch:

  • manufacturer: _TZ3000_wkai4ga5
  • model: TS0044

State Variables

  • driverVersion : 2.7.2 2024/05/06 11:24 PM
  • stats : {rxCtr=22, txCtr=0, rejoinCtr=0}
  • lastButtonNumber : 0
  • notPresentCounter : 0
  • comment : Works with Tuya TS004F TS0041 TS0042 TS0043 TS0044 TS0046 TS0601, icasa, Konke, Sonoff


Thank you all for the feedback - version 2.7.2 is now pushed for an update via HPM.


Sadly, I've had another instance of missed event (actually several missed activations for the same button).
Will it be possible to disable debouncing timer for _TZ3000_wkai4ga5 ?


@kkossev How about making the debouncing selectable for the device being controlled, since I have _TZ3000_wkai4ga5 and it appears to be working perfectively.

@iEnam, for me, the logs show an expected behavior... You can not press one and the same button quicker than 1 second between two consecutive clicks. This device automatically sends 2 or 3 repetitive events after the last button clicks; that's why it is the one-second debouncing filter in the driver code, ignoring the events from the same button that come in a less than 1000 ms time period.

You can check the above if you switch to the HE inbuilt "Tuya Zigbee Scene Switch" driver - there is no debouncing logic, and you will receive two or three repetitive events when you press buttons 2,3 and 4. Button 1 usually works fine. The reason for these repeated events is a bug in the Tuya device, which never got fixed.

@KurtSanders, I tried some time ago to make the debouncing configurable, but then I introduced another bug and had to revert to the previous driver version urgently. I will try again to add a configuration option when I have enough time to test the changes thoroughly.

1 Like

Thanks @kkossev,

If you are leaving the debouncing routine as is in driver version 2.7.2 for " _TZ3000_wkai4ga5" than no need/rush since my TS0044 device is working perfectly.

Thanks so much for your work on this, I have 4 of these remotes and love them using your device driver!


@kkossev, thanks for the explanation; the 1 sec debouncing makes sense.
The latest version has been working great, with your fix for "push twice to active" issue working great (not had this issue again!).

This missed event that I reported was very strange, as the button presses did not active the device until the device was manually turned on in device page.

So, let's call this an isolated incident as it is different to the fixed issue needing to push button twice to active.

If I have time, I will check the inbuilt driver and/or test your other driver "Zigbee button dimmer" which I use for the Tuya Smart knobs with debouncing disabled. Thanks again!

1 Like

Sorry, off topic.
Just wanted to pick your brains, I did setup a RTT graph similar to yours using the Meross Matter plug.
The rtt response time seems to be okay, but there are random blips with very high rtt...
Should I be concerned?


1 Like

I have occasionally seen similar high rtt blips with other Matter devices too.. Don't have an idea what could be the reason. But as long as it stays connected and does not result in timeouts, I think we are good.