I have a few Sonoff minis installed along with my swiches that turn on and off a few Yeelight RGB bulbs.
Overall it works OK: I can turn on/off the bulbs using the Sonoffs and once they are turned on, I can change the colors using the Yeelight integration.
So far, so good.
The issue is that once I turn the bulbs on, they take up to 5 minutes to show as available to Home Assistant.
I wanted a faster experience.
I know I can keep the bulbs energized and turn on/off by MQTT, but the problem with that approach is that when I leave home with my laptop, all integrations would stop and no one would be able to turn on/off the lights.
So, basically, I need something that tells HA that the bulbs are available as soon as I switch the Sonoff minis to on.
Is there any way to achieve that? Or perhaps another approach?
The bulbs need to reinitialize their network connection every time you cut the power to them. You could try putting the bulbs on a static IP, that should speed things up. (this can be tricky to do with some routers).
Sonoffs aren’t mqtt by stock so you’ve hacked some things. But you should also be able to use the Yee Alexia skill with or with out HA if you happen to have an echo around.
There’s are lots of other solutions out there. But they’re not plug and play and by the time you bought the extra components to do it. Well, you may as well just buy a used Pi and run HA from that.
Bulbs are already using fixed IPs and integrated to HA using those IPs, and still take up to 5 minutes to show up as available.
Curiously, in the Yeelight app they show up and can be set in a matter of seconds, which makes me think there is a faster way to detect the availability.
Did you set the static IP up in both the HA config yaml and your Router?
My yeebulbs don’t normally take more then 5 or 10 seconds to show up in HA after a power cycle (I have them on normal wall switch). But they’re older ones and they’re also set in “dev” mode. Dev mode was renamed to something else that I can’t remember now.
I’ve never had problems with this setup. It’s been on two different systems - pi and x86 with different routers.
Interesting.
Mine are set for fixed IPs in the router and in the HA config as well:
discovery:
ignore:
- yeelight
# YEELIGHT
yeelight:
devices:
192.168.0.50:
name: Luz do Quarto Principal
192.168.0.51:
name: Luz do Centro da Sala
192.168.0.52:
name: Luz da Sala de TV
192.168.0.53:
name: Luz do Escritorio
192.168.0.54:
name: Luz da Porta
192.168.0.55:
name: Luz da Sala de Jantar
192.168.0.56:
name: Luz do Banheiro
192.168.0.57:
name: Luz do Quarto Bebe
192.168.0.58:
name: Luz da Lavanderia
192.168.0.59:
name: Luz da Sacada
192.168.0.60:
name: Luz da Cozinha
192.168.0.61:
name: Abajour Bebe
192.168.0.62:
name: Abajour Quarto