devbobo / homebridge-lifx-lan

LiFx LAN platform plugin for Homebridge
MIT License
84 stars 27 forks source link

Bulb stuck updating in Home App - not responsive #25

Open ajwilkz opened 7 years ago

ajwilkz commented 7 years ago

Hi,

So my LiFx 3rd gen colour bulb used to work fine with Homebridge and the Lifx-lan plugin. Then my housemate tried to use the bulb on the dimmer switch, which messed up the bulb and it went into recovery mode - we brought it back, all fine - working perfectly with the LiFx app.

The problem now is that the bulb appears in home the home app, but it constantly stuck updating, and is complelty unresponsive. The home app has also lost the colour setting for the light. I've tried:

-removed the platform using the Hesperus App -renamed the light -deleted the cached accessories file -deleted and reinstalled the home app -disconnected iCloud -completley reinstalled Raspbian/homebridge/homebridge-lifx-lan

...all with no luck, every time the bulb comes back in the home app - stuck updating. It's also effecting the other accessories in the home app as they start experiencing updating problems when i add the life-lan plugin back to home bridge.

img_0231

Any advice?

beatmag commented 7 years ago

You need to delete your persist folder for homebridge to forget the accessory. After doing this add the bulb again.

ajwilkz commented 7 years ago

Thanks @beatmag that's fixed the issue. Would you happen to know how to keep scenes in the iOS home app after Homebridge restarts? Every time I restart Homebridge I loose my scenes?

devbobo commented 7 years ago

Please try version 0.2.1 and let me know if it resolves this issue.

ajwilkz commented 7 years ago

Hi @devbobo, I've updated Homebridge but I'm still faceing the same issues. Everything will be working fine, then 24hrs later I get 'no response' from Homebridge in the home app!

beatmag commented 7 years ago

0.2.1 is much better however the following timings are required.

Lightofflinetolerance 2 Messagehandlertimeout 2500 Resend packet delay 500 resend max times 3

ajwilkz commented 7 years ago

Thanks for your help! I haven't had any problems since updating to 0.2.1 and deleting all the scenes I had made using the HMCatalog.

starlessblack commented 7 years ago

I've frequently been having issues when launching the Home app where I have to wait an exceedingly long time while all the devices are "updating". I have several LIFX bulbs, Nest thermostat, and HarmonyHub. I'd read many folks talking about the LIFX bulbs being the culprit but am not entirely convinced, however I just updated this plug from 0.2.0 to 0.2.1 so we'll see how it goes.

ajwilkz, what did you mean by "deleting all the scenes created using the HMCatalog"?

devbobo commented 7 years ago

I'm beginning to wonder if this is an issue with how Homebridge itself handles status updates or requests for updates.

I run 6 platform plugins with numerous accessories (31 in total). As a test, today I have split each platform plugin out to run on it's own instance of Homebridge. So far when I load the Home app I get pretty much instantaneous status of my favourite accessories while on the same wifi network as my RPi3...previously, I may have to wait up to 10 seconds.

I'm going to continue running it like this for a while to see how things go after the instances have been running for a few days.

ajwilkz commented 7 years ago

@devbobo I'm still have to restart Homebridge every couple of days to get access when all my devices are 'updating' - how have you been getting on?

@starlessblack it's an iOS app I'm using in conjunction with the Apple Home app, search 'HMCatalog' in the App Store.

starlessblack commented 7 years ago

I've got my Homebridge running as a service, and I started having it restart every 24hrs in the middle of the night. While that does seem to be helping and lessening the number of times I encounter the "updating" devices, the thing that gets me is that the problem appears to occur far more often on my phone than my iPad. Now I am using my iPad as a Homekit Hub, so perhaps the app is updating in the background more frequently on the iPad.

The other head scratcher is that I think, possibly, maybe, Homebridge was a lot more stable and I encountered this problem less frequently back before I started running it as a service. I'm considering going back and changing it to an ad-hoc program I call from the command line, but then maybe my memory is just faulty.

Do you all run yours as a service at startup?

starlessblack commented 7 years ago

Here's another question: do any of you also happen to run the HarmonyHub plugin for Homebridge? I tracked down what I believe to be a HarmonyHub plugin issue (that plugin is, unfortunately, it seems hampered by problems not easily addressed by the 3rd party dev who created it), and when I powercycled my Harmony Hub, my Homebridge has been much more responsive and hasn't been stuck "Updating..." devices in a while. I'm going to continue powercycling the Harmony Hub every few days and not reboot Homebridge, and see how it goes.

devbobo commented 7 years ago

@ajwilkz running each plugin on it's own instance of Homebridge, has made a huge improvement. When using the Home app on my local network, all my accessories respond instantly and I haven't had to do any reboot of my rpi which I was having to do at least once a week. After having a discussion with some other 3rd party developers, it seems logical that Apple never expected to have some many accessories running off a single bridge accessory

devbobo commented 7 years ago

@starlessblack yes, I run the homebridge-harmonyhub plugin...as I've stated in my past few posts, I've started running each of my plugins on it's own instance of Homebridge. I also run all my Homebridge instances as a service...which method are you using to do this ? On what platform ?