Closed socalcal closed 5 years ago
I guess this repository is no longer supported? Is there a new tuya homebridge repository that's active?
Please give the latest rc
release a shot by doing npm i -g homebridge-tuya-lan@rc
. It includes logic to understand this newer API.
A known issue is that the current state is not reported by some devices; they however work fine as soon as you interact with them. I have reached out to Tuya for a solution.
The Setup Instructions have changed in case you need to obtain a fresh id
and key
.
Thanks for the response. I installed the rc release and am now getting this:
[9/7/2019, 12:52:03 PM] [TuyaLan] Patio - identify [9/7/2019, 12:52:05 PM] [TuyaLan] Patio - identify [TuyaAccessory] Socket had a problem and will reconnect to Patio (Error: ERR_PING_TIMED_OUT) [TuyaAccessory] Sending first query to Patio (3.3) [TuyaAccessory] Socket had a problem and will reconnect to Patio (Error: ERR_PING_TIMED_OUT) [TuyaAccessory] Sending first query to Patio (3.3) [TuyaAccessory] Socket had a problem and will reconnect to Patio (Error: ERR_PING_TIMED_OUT)
My config.json has this device entry:
"name": "Patio",
"type": "MultiOutlet",
"manufacturer": "LARKKEY",
"model": "Outdoor Smart Outlet",
"id": "0008XXXXdc4f22f3XXXX",
"key": "7d9XXXX5206bXXXX",
"outletCount": 2,
"ip": "10.0.1.125"
If you have the latest rc
, please add "pingTimeout": 3600
to your config to see if we can get rid of the ping timeouts. The rc
has been changing frequently. Please get rid of the ip
from your config while you are at it.
After you restart homebridge:
Sending first query to Patio (3.3)
This is what I see after: [TuyaAccessory] Socket had a problem and will reconnect to Patio (ECONNRESET)
Yes, but somehow I got them to actually register, but turning on/off does nothing. I'm not sure how I got the exclamation points to go away.
No messages when turning on/off at device.
I did, however run the tuya app while homebridge was running and the sockets register the correct status when turning on/off with the tuya app. Using Home app does nothing other than change the status while not affecting the outlet at all.
Can you please post 15-20 lines of sequential logs? If you are on macOS or linux, use tail
and | grep Tuya
. The sequence of messages (preferably with timestamps) will let me draw an accurate picture of this; what I need to see would start with Discovered
and at least 45 seconds after it.
Also, from our conversation, I haven't seen anything to give me confidence that we have the correct key
. Are you using the key from May or did you get a chance to get the key
with the new instructions?
Here's what I get with tail:
[9/7/2019, 3:50:23 PM] [TuyaLan] Discovered Patio (00087488dc4f22f3403d) identified as MultiOutlet (3.3) [9/7/2019, 3:50:23 PM] [TuyaLan] Connected to Patio [TuyaAccessory] Sending first query to Patio (3.3) [TuyaAccessory] Socket had a problem and will reconnect to Patio (ECONNRESET) [TuyaAccessory] Sending first query to Patio (3.3)
I used the new instructions and got the same key I was using before.
I couldn't find the 2-outlet one on Amazon to buy and check. Did you buy it from Amazon yourself?
Yes, and the link I provided in the original post is the same that's shown in my order history. Apparently links to a different product now.
Link for amazon.com.uk: https://www.amazon.co.uk/LARKKEY-Outdoor-Outlet-Compatible-Contrilled/dp/B07LGS6BS3
From the box: Outdoor Smart Outlet Model Number: SOP04-US Waterproof Level: IP44 Parameters: AC 100-240V 50/60Hz Max Power: 1875W(resistance loading) Max Current: 15A Rated Voltage: 125V Working Temperature: -20~60°C(-4~140°F) Remote Control: Smart Life APP (Compatible with Android 4.1/IOS 8.0 or above)
UPC is X001ZINZLN LARKKEY Smart Outdoor...led, 2 AC Plugs, Black
This one appears to be the same: https://www.amazon.com/TECKIN-Compatible-Smartphone-Weatherproof-certified/dp/B07KB63CYN/ref=sr_1_4?keywords=teckin+smart+outdoor+outlet&qid=1567898466&s=gateway&sr=8-4
If you don't have a Mac, or don't think you can help with some debugging, I will go ahead an order one. Lemme know please.
I have a Mac and am willing to help debug, but I only have rudimentary terminal knowledge. You’ll have to be patient and give super simple instructions that I’ll be able to follow.
Hehehehe. Of course. You are the 3rd person I am sharing this info with today so I think it would be best to just make a document about the steps.
You can find the documentation here. It is really simple but looks big because I have tried to explain as much as possible.
Let me know if you have any questions and thanks for helping me save the 25 bucks of buying the plug.
@socalcal, before you do the sniffing, please update to the latest rc
using npm i -g homebridge-tuya-lan@rc
. Someone sent me their packet logs which resulted in changes that fixed their similar problem; it might solve yours too.
I totally missed the message with the instructions in it, but I just installed the rc and it works! Thanks so much!
That's great news. Best of luck.
@socalcal I have 2 LED Larkkey lights that I want to get into Homebridge. Would you be interested in getting this working also?
I don't have a need, but if you're looking for assistance, you should probably send a message to AMoo-Miki or open a new issue.
Product link:
https://www.amazon.com/gp/product/B07LGS6BS3/ref=ppx_yo_dt_b_asin_title_o03_s00?ie=UTF8&psc=1
I initially set this up as a MultiOutlet with the following in config.json:
{ "platform": "TuyaLan", "devices": [ { "name": "Patio", "type": "MultiOutlet", "manufacturer": "LARKKEY", "model": "Outdoor Smart Outlet", "id": "mydeviceid", "key": "mydevicekey, "outletCount": 2, "ip": "mydeviceip" }
Upon starting homebridge, I got:
[TuyaLan] Failed to discover Patio (mydeviceid) in time but will connect via mydeviceip. [TuyaAccessory] Socket had a problem and will reconnect to Patio (Error: ERR_PING_TIMED_OUT) [TuyaAccessory] Closed connection with Patio [TuyaAccessory] Socket had a problem and will reconnect to Patio (Error: ERR_PING_TIMED_OUT)
I changed config.json to SimpleLight and got this:
[TuyaLan] Failed to discover Patio (mydeviceid) in time but will connect via mydeviceip. [TuyaLan] Patio has a different type (7 vs 5) [TuyaLan] Unregistering Patio [TuyaLan] Connected to Patio [TuyaAccessory] Socket had a problem and will reconnect to Patio (Error: ERR_PING_TIMED_OUT) [TuyaAccessory] Closed connection with Patio [TuyaAccessory] Socket had a problem and will reconnect to Patio (Error: ERR_PING_TIMED_OUT) [TuyaAccessory] Closed connection with Patio
Hope this helps? Any ideas? Thanks!