Skip to content

Improvement : Remove the auto power of for some tuya switch #5118

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 19 commits into from
Closed
Show file tree
Hide file tree
Changes from 18 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 10 additions & 0 deletions bindings.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
#include "device.h"
#include "device_descriptions.h"
#include "utils/utils.h"
#include "product_match.h"

#define MAX_ACTIVE_BINDING_TASKS 3

Expand Down Expand Up @@ -2690,6 +2691,15 @@ void DeRestPluginPrivate::checkLightBindingsForAttributeReporting(LightNode *lig
{
return;
}

// Hack : Need to disable reporting for thoses devices, else It will enable a auto power off after 2mn.
// see https://github.com/dresden-elektronik/deconz-rest-plugin/issues/3693
if (lightNode->manufacturer() == QLatin1String("_TZ3000_fvh3pjaz") ||
lightNode->manufacturer() == QLatin1String("_TZ3000_9hpxg80k") ||
lightNode->manufacturer() == QLatin1String("_TZ3000_wyhuocal"))
{
return;
}

auto i = lightNode->haEndpoint().inClusters().begin();
const auto end = lightNode->haEndpoint().inClusters().end();
Expand Down
5 changes: 5 additions & 0 deletions product_match.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,8 @@ static const ProductMap products[] =
// Tuya_COVD : covering device using Tuya cluster
// Tuya_RPT : Repeater
// Tuya_SEN : Sensor
// Tuya_SWITCH : Wired Switch
// Tuya_DIMSWITCH : Wired Switch with dimmer

// Tuya Thermostat / TRV
{"_TYST11_zuhszj9s", "uhszj9s", "HiHome", "Tuya_THD WZB-TRVL TRV"},
Expand Down Expand Up @@ -104,6 +106,9 @@ static const ProductMap products[] =
{"_TZE200_la2c2uo9", "TS0601", "Moes", "Tuya_DIMSWITCH MS-105Z"},
{"_TZE200_dfxkcots", "TS0601", "Earda", "Tuya_DIMSWITCH Earda Dimmer"},
{"_TZE200_9i9dt8is", "TS0601", "Earda", "Tuya_DIMSWITCH EDM-1ZAA-EU"},
{"_TZ3000_fvh3pjaz", "TS0012", "Tuya", "Tuya_SWITCH 2 Gangs"},
{"_TZ3000_9hpxg80k", "TS0011", "Tuya", "Tuya_SWITCH 1 Gangs"},
{"_TZ3000_wyhuocal", "TS0013", "Tuya", "Tuya_SWITCH 3 Gangs"},

{nullptr, nullptr, nullptr, nullptr}
};
Expand Down