Thank you very much once again, NicoIIT. The fix has worked perfectly. Furthermore, it has solved another problem I encountered today. It was impossible for me to create an automation that included adjusting both the brightness and the color temperature. Only one of the two worked, and sometimes neither. It seemed as if trying to apply both settings at the same time interfered with each other. But that has now been resolved with this update.
But I think I’ve found another problem, although it should be easier to fix. When the integration detects that the adjustment to send is the same as the light already has, it doesn’t send it. Let me explain. If, for example, I set the light intensity to 30% and then wanted to send that 30% setting again, the integration doesn’t send the command. In my case, I have created several automations changing the light’s temperature and brightness according to the time of day when the light turns on. But for example, if the setting is at 30% from 10:00 PM to 11:00 PM, I run the automation at 10:00 PM and the brightness changes to 30%. If someone then changes the brightness with the remote control or the light’s controller changes it randomly (as it sometimes does), the integration will not send the command again when the automation is executed because it believes it is already at that percentage. I have tried changing the percentage in the automation by 1% and running it, and it works again, so that’s my assumption.
Thank you very much for your time!!"
The fix has worked perfectly
Lucky me
I think I’ve found another problem, although it should be easier to fix
You have no idea how wrong this sentence can be
When the integration detects that the adjustment to send is the same as the light already has, it doesn’t send it
Indeed, this is how the framework works: it acts based on the difference in between the assumed state before and after a command. I am not sure what could be the effort needed to change this but it could be important, not sure I want to change this…
Another possibility would be to re send all commands on each change, but this would imply delays in the effective wanted command so it would be a regression for 99% of the users.
If someone then changes the brightness with the remote control
You can link your remote control to the HA integration to synchronize its state, this would at least solve this part of your issue. If your remote is not supported you can open an issue to have it supported.
the light’s controller changes it randomly
There are limits to what is humanly possible to code .
You can also activate the option “Force (…) refresh on Switch ON” which will force the re send of the brightness / CT when the light is switched ON, which gives you a workaround (switch OFF then back ON) to re synchronize the light.
Ha ha, you’re absolutely right. As soon as I wrote the answer I thought it was too arrogant
. Especially since I have no idea about programming. I’ve already synced the remote control (I didn’t even know that was possible). As for the rest, I’ll just modify the automation to check the brightness and temperature values, and if they’re the same, It’ll add +1 to them and that’s all. The change should be imperceptible to the eye. Since your last update, the automations have been working really well.
Thanks a lot for your work.
For those trying to use ha-ble-adv
with Bluetooth lamps on macOS, I’ve written a tutorial post documenting my experience and step-by-step guide. Check it out here: Tutorial: Integrating Bluetooth Ceiling Lamp into HomeKit on macOS
Thanks to @NicoIIT for this amazing integration!
Hi @NicoIIT Is there some special configuration beside adding the repo from HACS and adding the Device from Integrations as it does not control the lamp.
The protocol that is detected is lamppro_v1 that corresponds to the app version 1.4.1 that I use to control the lamp. When using the Android app the lamp temp control/brightness/state in HA are changed. But when I try to control the lamp from HA it’s not working. Maybe because the lamp is already paired with my phone and can’t be controlled by the HA?
HA is installed on Proxmox VM if that matters but I think if the app commands are detected by the integration all the hardware should be able to control the lamp, too.
Thanks for efforts btw
P.S. Just forgot to mention that the blink thing is not working in my setup for any of the options (I haven’t used the third one as I don’t now what indexes to use)