-->
Page 1 of 25

WS2812B RGB LED Driver

PostPosted: Wed Jan 07, 2015 4:53 am
by Markus Gritsch
Working code to drive WS2812 LEDs from an ESP8266 is already available here:

https://github.com/cnlohr/ws2812esp8266

It just needs to be integrated into NodeMcu :)

Re: WS2812B RGB LED Driver

PostPosted: Wed Jan 07, 2015 5:21 am
by gwizz
Hey - great suggestion - I'd love to see these things work off my new favorite chip!!

Two questions in general - what's required to integrate a feature for which C code is already available?

I've vaguely gathered that lua makes it easy to integrate C libraries - what sort of plumbing is needed?

And the other one is more general - which stuff should be inside nodemcu - consuming precious space for everyone - and which should be in userland?

Perhaps we need a guide to compiling nodemcu with our own particular set of modules?

Now that zeroday (and others?) have worked hard to make compilation more widely available, perhaps the answer is to have an easy guide to commenting them out from the code?

Re: WS2812B RGB LED Driver

PostPosted: Fri Jan 09, 2015 4:25 pm
by cocojackr42
Perhaps we need a guide to compiling nodemcu with our own particular set of modules?

+1

If there was a Hardware SPI Lib, we could implement the RGB as a lua module...

Re: WS2812B RGB LED Driver

PostPosted: Sat Jan 10, 2015 4:09 pm
by Markus Gritsch
cocojackr42 wrote:If there was a Hardware SPI Lib, we could implement the RGB as a lua module...

Yes, I did it this way with the MicroPython board: https://www.youtube.com/watch?v=GHmoE9ui4NU
However, putting together the SPI data in the interpreted language has its performance limits.