dotsam / homebridge-milight

MiLight/LimitlessLED/Easybulb Plugin for Homebridge
MIT License
63 stars 12 forks source link

Brightness/Colour Temp on Non-rgbw bulbs #4

Open dotsam opened 8 years ago

dotsam commented 8 years ago

rgb and white bulbs only support up/down commands for brightness and colour temp, not an absolute value. Currently we handle this by simply sending a single up/down command based on which side of the midpoint the commands are for.

There are a known number of steps for each of these values that the bulbs support, so ideally we would keep track of these and send the appropriate number of steps to get to the users desired values. This will have to be worked out with #3 to ensure we don't have to send 10+ commands for each percentage the user selects on a slider. Also have to confirm 100% how/if Homebridge keeps track of this data already to read from it.

dotsam commented 7 years ago

Basics are implemented in ad8e46d1e5dcee8489ff7df815b6c1413dd1666a but I still want to try and work this in with #3 as well so things work as smooth as possible.