-
Notifications
You must be signed in to change notification settings - Fork 13
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Initial support for milight white bulbs #43
base: master
Are you sure you want to change the base?
Conversation
See #42 |
color = Color(@color).rgb() | ||
@device.sendCommands(nodeMilight.commands.rgbw.rgb255(color.r, color.g, color.b)) | ||
|
||
if @config.type == "White" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would prefer to have the bulb types as static var of the Milight class:
class Milight extends BaseLedLight
@BULB_TYPE:
WHITE: 'White'
COLOR: 'Color'
...
turnOn: ->
...
if @config.type is Milight.BULB_TYPE.WHITE
@philip1986 I don't think we should add a type property to the Milight device class as suggested by @bjornhij, but there should a new device class for this. Note, the contributed code does not handle dimming which works a lot different from RGBW dimming. With CW/WW LEDs the command set does not provide dimming value, but it provides commands to increase and decrease brightness. So, CW/WW need a UI class of its own. |
@mwittig ok I got your point and I agree. |
I've created a new MilightCWWW class. Still figuring out how I can use another UI class. |
Color and brightness UI elements still there, but unusable.