Closed mweinelt closed 7 years ago
Thanks! I have not encountered this, but I have not left my server on for long periods as you described. I am using a HS100. Perhaps @kirichkov can share his experience too.
I was looking at the Hue component in the Home-Assistant library.
I will try to add in and test a throttle function soon, but seems like the default setting on Home-Assistant is set at 30 seconds?
I have observed this, whenever I force quit homeassistant (Multiple times Ctrl+C). I found out that the process that accept the control commands stops listening on the port. It is possible that the process dies or the socket is hung on the switch but closed on the HASS end. This never happened to me when exiting cleanly - dev services / shutdown, but I've never ran home assistant for more than a day because I got the socket a week ago, and was working on implementing the energy meter.
Can you give me some more information - besides hass do you use the phone app? I'm suspecting the process might have a bug if two hosts try to simultaneously communicate with the switch.
I'll start testing and report back.
As a last resort we can consider adding a remote reboot method that uses the TP-Link debugging protocol which runs in a different process on port 9999.
Proof of concept is available at https://github.com/softScheck/tplink-smartplug/. Given this is covered by a patent I'm not sure whether we can legally implement it without TP-Link's approval.
I believe this switch is only being switched on in the morning and switched off in the evening, nothing more. The instance there is usually being restarted from within homeassistants frontend.
Some more ideas - when you notice this happening can you check via nmap or nc whether the power plug is actually listening on port 9999/tcp. Let me know if you need help how to do this.
Also - have you connected it to the tp-link cloud, if so, and when you get a connection refused, can you check whether you can switch it on/off via the tp-link cloud?
I will check when it happens the next time. The device is not cloud connected.
This happened to me yesterday, while I was fiddling with hass and starting and stopping it, but it also happened during the night, so it's probably buggy firmware.
I noticed today that the device has been inactive since sunday. It's sitting plugged in, but no light is on, the button on the device does not react either and the plug wasn't on the wifi network.
It works again after disconnecting it from the power socket and reconnecting it.
Mine has been running without a glitch for almost two weeks now. In my case the button does toggle the relay and the light is working. I noticed other people on amazon reviews have the same experience but using the TP-Link Kasa app.
I noticed there will be a new plug - HS105 - hopefully there will be a firmware upgrade that resolves this issue, otherwise this plug becomes pretty useless.
My plug has started crashing - never surviving for more than 3 hours, after I moved it to a different location. The only difference from my home where it was working reliably for a few weeks is that voltage is very unstable - it's usually 210-220V but sometimes it drops to 180V for very short periods. I'm also running a PowerLan but that shouldn't interfere with the plug.
@mweinelt have you noticed similar low voltage around the time your plug crashes?
No new data from my end yet, sorry. The thing has been stable for a while now.
I expect this will benefit from the protocol changes correctly handling the packet size as well.
Let's see. I'm 90% sure that my problems are caused by either low voltage (I've seen it drop to 160V) or the fact I'm running powerlan and it's causing some interference. I put the plug at a different location and it's running steadily but voltage is 230-240V.
Any update on this on the newest release? If not, maybe the reason is really the voltage jumps and there's nothing we can do about it, in which case this issue could be closed.
Let's close it. I'll give the newest release a try and report back. If it's still crashing and we don't get any further feedback suggesting otherwise I consider it voltage-related.
I'm using a HS110 via Home-Assistant and every few weeks there seems to be a process on the device dying, so it becomes unqueryable, uncontrollable.
Is this a known issue? Is there a solution?
Is it possibly hammering the service until it gives up? The access to the state property is not being throttled, see https://github.com/home-assistant/home-assistant/blob/dev/homeassistant/components/switch/tplink.py#L51-L54.