sonicare-ble-hacs
sonicare-ble-hacs copied to clipboard
Anyway to decrease the startup time of the integration? Stalls and warnings if a previously setup brush is in sleep/offline/dead
I LOVE that you took the time to create this integration. Works perfect with my Oral B integration so now everyone in the family can utilize it both brands. The kids use a Sonicare4kids brush. It was setup okay, but if its ever offline, sleeping, or dead, the integration spams the logbook on trying to reconnect. On a home assistant restart, if the brush is sleeping, it delays the startup by a minute
Not only that, but it appears even after home assitant loads, the integration keeps trying over and over again to reach the brush instead of first listening to a brush advertisement then trying
That's a no-go in my eyes. Custom integrations blocking Core starts need to urgently be fixed (or uninstalled).
Hi @GrumpyMeow ,
Is it possible to check the reason behind the long startup time?
Hi all, i took some time to look into the said issues. I've based the implementation on the ld2410-ble code. I put the ld2410-code next to the Sonicare-code and there is no difference.
The toothbrushed do send advertisements, but every time the same data. Unfortuntatly advertisements with the same data gets ignored by Home Assistant. To work around this, a connection needs to be made with the toothbrush even without receiving an advertisement. This as an advertisement might already be received before the toothbrush is configured.
I will look into it some more, maybe i find a better solution.
@GrumpyMeow I think I've solved the issue with advertisments by async_rediscover_address in my fork. I've also solved the startup failure.
- Feel free to apply some patches from my fork…
- Could you add a license file, please?