Closed explorador closed 4 years ago
What does your config.json
look like?
"platforms": [
{
"platform": "TuyaPlatform",
"name": "TuyaPlatform",
"devices": [
{
"name": "Power Strip",
"id": "xxxxxxxxxxxxxxxxxxxxx",
"key": "xxxxxxxxxxxxxxxxxxxxx",
"ip": "xxxxxxxxxxxxxxxxxxxxx",
"options": {
"dps": 6
}
}
]
}
]
Power strip turns on/off fine, the status is just wrong
It doesn't look to me like DPS 6 actually controls anything... have you tried other DPS indices?
Other DPS are fine. I just tested them out and their status are accurate.
DPS 1 - 4 are outlets, DPS 5 is USB, DP6 is master (All-ON/OFF according to the Tuya app). it works fine but status is wrong cause it returns 0
instead of true/false
Oh, I see the issue.
There's no single status property for the master switch, it's just whether or not all other properties are set to true.
Unfortunately, in its current state, homebridge-tuya can't really work with devices like this. My recommendation would be to make a scene that turns all properties on and off.
I'll look into adding support for this whenever I next have my one-day hackathon of updating my NPM modules. 😛
(I'm copy/pasting this into every open issue and PR.)
This plugin is now deprecated, as I don't have enough time to maintain it along with other TuyAPI related projects. Please use AMoo-Miki's homebridge-tuya-lan plugin instead. (Or, you can continue to use this plugin, but I will not be giving support or adding any new devices.)
I'm sorry about this, but this plugin is taking a disproportionate amount of my time that I believe is better spent making TuyAPI more stable and adding more tools to the ecosystem.
Closing; inactive thread. If you need support please re-open this issue.
master switch (dps: 6) is getting a value of 0 and homekit always says it's off when I close/reopen the app. This is the output when master switch is on:
{ devId: 'xxxxxxxxxxxxxxxxxxxxx', dps: { '1': true, '2': true, '3': true, '4': true, '5': true, '6': 0 } }
Output when master switch is off:{ devId: 'xxxxxxxxxxxxxxxxxxxxx', dps: { '1': false, '2': false, '3': false, '4': false, '5': false, '6': 0 } }