toblum/McLighting

Request: RGBW Mode

semaf opened this issue · 12 comments

semaf commented

Hey,

Is it possible to support RGBW Leds like SK6812 Strips?

I think this may be possible as the Adafruit library seems to support these, at least in RGB mode. I don't know how the W can be adressed. But maybe you can give it a try if you have a SK6812 at hand.

Regards
Tobias

semaf commented

As you talk to RGB with each bit, you have to talk to the 4th bit too which is seperate white to rgb.

I have tested it over Homebridge with Homekit and the 4th bit, the W was lighten on. But your Arduino and index.htm can not handle with it, the brightness lower or higher or on off of the 4th bit. I did not study your complete code, just uploaded and tested ;P Need time to check it and give a test but could take time as I am not free.

Edit: Shortly found this here

Arduino Sketch for RGBW: https://github.com/adafruit/Adafruit_NeoPixel/blob/master/examples/RGBWstrandtest/RGBWstrandtest.ino

Adafruit_NeoPixel.h
https://github.com/adafruit/Adafruit_NeoPixel/blob/master/Adafruit_NeoPixel.h

void loop() {
  // Some example procedures showing how to display to the pixels:
  colorWipe(strip.Color(255, 0, 0), 50); // Red
  colorWipe(strip.Color(0, 255, 0), 50); // Green
  colorWipe(strip.Color(0, 0, 255), 50); // Blue
  colorWipe(strip.Color(0, 0, 0, 255), 50); // White

  whiteOverRainbow(20,75,5);  

  pulseWhite(5); 

  // fullWhite();
  // delay(2000);
  rainbowFade2White(3,3,1);

}

Just to update this, McLightning works with RGBW Pixels but without using the white-channel.

Simply change the pixel type in the WS2812FX init from

WS2812FX strip = WS2812FX(NUMLEDS, PIN, NEO_GRB + NEO_KHZ800);

to

WS2812FX strip = WS2812FX(NUMLEDS, PIN, NEO_GRBW + NEO_KHZ800);

Hi Tobias,
any plans to implement this?
I would be really interested for having a combined "normal" lamp with RGB options for the kids rooms
Thanks, ESP boards are on the way...;)

HI @martinschki,

there is already a fork of McLighting that provides support for RGBW. Unfortunately it's not so easy to integrate into the main code, but you could give it a try: #94

Best regards
Tobias

Any news on this? I think McLighthing works really well, but lacking support for RGBW is a real bummer.

Support for RGBW is the difference between it being a fun project, and then being actually useful in a home.

Have look here:
https://github.com/FabLab-Luenen/McLighting
Unfortunately it‘s a separate effort, but I still hope that it will be integrated into the „master“ at some point in time.

I've been looking at that one, but as you say it's a separate effort - which isn't necessarily bad, but I would have preferred a joint effort :)

Just to update this, McLightning works with RGBW Pixels but without using the white-channel.

Simply change the pixel type in the WS2812FX init from

WS2812FX strip = WS2812FX(NUMLEDS, PIN, NEO_GRB + NEO_KHZ800);

to

WS2812FX strip = WS2812FX(NUMLEDS, PIN, NEO_GRBW + NEO_KHZ800);

Where do I find this file that needs the change? Also, has official W support ever been fully integrated?

@VeniceNerd The changes from the develop branch were merged to the main branch a bit accidentially. That messed up everything. So you should now have all RGBW changes also in the main project, but they're not complete now and not really tested so far. I think I'll have to do a bit housekeeping to clean up everything.
The mentioned lines can be found in McLighting.ino

Did anything happen in the meantime in the direction of RGBW integration or housekeeping?
I think SK6812 RGBW will get more and more important and it would be great if it could be supported.

Did anything happen in the meantime in the direction of RGBW integration or housekeeping?
I think SK6812 RGBW will get more and more important and it would be great if it could be supported.

Just use this fork. https://github.com/FabLab-Luenen/McLighting