AMoo-Miki / homebridge-tuya-lan

Homebridge plugin for IoT devices that use Tuya Smart's platform
MIT License
200 stars 51 forks source link

'MultiOutlet' Device not working #154

Open AntlerDM opened 4 years ago

AntlerDM commented 4 years ago

I have a smart power strip that is having a communication error of some sort. It appears that the device is not discoverable. I have configured it with and without "ip". Here are the details.

Device: CE Smart Home - Smart Home Power Strip 6 Controls in Ucomen Home app (Main Power Button + 5 Controlled Outlets) IP Address is statically assigned at router (ping: address is reachable only when device is plugged in)

Environment: HOOBS Version 3.1.20 Homebridge Version 0.4.50 Node Version 10.18.0 Tuya Lan Version 1.4.0 (published 9/15/2019)

Configuration: { "platform": "TuyaLan", "devices": [ { "name": "Power Strip", "type": "MultiOutlet", "manufacturer": "CE Smart Home", "model": "Smart Wifi Power Strip", "id": "XXXXXXXXXXXXXXXXXXX", "key": "XXXXXXXXXXXXXXX", "outletCount": 5, "ip": "192.168.XXX.XXX" } ] }

Homebridge Log...

[Homebridge] [1/19/2020, 4:36:44 PM] [TuyaLan] Starting discovery...
[Homebridge] [TuyaAccessory] Discovery started.
[Homebridge] [1/19/2020, 4:37:44 PM] [TuyaLan] Failed to discover Power Strip (XXXXXXXXXXXXXXXXXXX) in time but will connect via 192.168.XXX.XXX.
[Homebridge] [TuyaAccessory] Socket had a problem and will reconnect to Power Strip (EHOSTUNREACH)
[Homebridge] [TuyaAccessory] Closed connection with Power Strip
[Homebridge] [1/19/2020, 4:37:52 PM] [TuyaLan] Connected to Power Strip
[Homebridge] [TuyaAccessory] Socket had a problem and will reconnect to Power Strip (Error: ERR_CONNECTION_TIMED_OUT)
[Homebridge] [TuyaAccessory] Closed connection with Power Strip
[Homebridge] [TuyaAccessory] Socket had a problem and will reconnect to Power Strip (Error: ERR_PING_TIMED_OUT)
[Homebridge] [TuyaAccessory] Closed connection with Power Strip

If I turn on/off any power button on the device (using Ucomen Home app)...

[Homebridge] [TuyaAccessory] Odd message from Power Strip with command 8: { cmd: 8, data: 'Áî\u0017\u0000Ð4›½\u0006dÂgÆcs6ž\u0003ÆÙ1·ÇÊü\u0010ê}\u001c\u0017Y' }
    (data value is different for every event, even if I press the same button)
rdetert commented 4 years ago

I'm getting the same thing but with the TESSAN Outdoor Wifi Outlet. I also had to specify the IP manually. Using the Ucomen Home app I was able to get the correct ID and Key and the device does show on HomeKit and no longer says "Not Responding". But it still doesn't work and eventually the bad connections will cause homebridge to run out of memory and quit.

My config looks identical to the OP.

Here is my error.

[TuyaAccessory] Odd message from Outdoor Lights with command 8: { cmd: 8, data: 'Iù47/ýßcWö]ËBÌh\u000e' }

EDIT

I found it easier to just buy a new device