Go Down

Topic: Adafruit_NeoPixel vs. FastLED (Read 17105 times) previous topic - next topic

Helmuth

Oct 30, 2015, 11:14 am Last Edit: Oct 30, 2015, 11:31 am by Helmuth
Hello everyone,

with all humbleness I wonder why people still recommend to use the Adafruit library.

Compared to FastLED in nearly all situations the NeoPixel library

-uses more RAM,
-the compiled sketch built is larger and
-the delivered frames per second are less

For a detailed comparison have a look here.

FastLED also offers way more useful functions for led animations like

-fast math and memory functions,
-wave functions
-simplex noise functions
-color palettes
-build in gamma and color correction

to name just a few advantages.

Beside that FastLED supports not only Neopixels but basically any led controller on the market.

Could anyone tell me a logical reason, why or in which scenario the Adafruit library is the better choice?

I'm sure I'm just overlooking something here, but I don't get it yet. So I'm asking!

Cheers and thanks for any hint.

Helmuth

PaulRB

Thanks for the review and recommendation, Helmuth. I am half way through a project using the Adafruit library, so when I get back to it, perhaps I will swap libraries and see what difference I notice (ram, program size, etc).

I suspect the answer to your question is that the ws2812b leds have been nicknamed "neopixels" and the name has stuck. So when a lot of Arduino users go looking for a library, the search term they use is "neopixels" and they find the Adafruit site and so on.

Paul

zencuke

Basically the NeoPixel library came first, is simple to install and use, and Adafruit supports it; making things simple if you are a beginner and buy from them. Note that even the Adafruits NeoPixel Uberguide recommends FastLED for advanced use. Some of their tutorials use it instead of the NeoPixel library.

Chris72622

Interesting thread!

Maybe some more people could tell about their experiences!

Nearby i'd like to build a stairslight and i'm actually not sure which library i should use.

Want to use these stripes.



Greetz Chris
Bilnk wtiohut daley.

Helmuth

#4
Feb 01, 2016, 12:22 pm Last Edit: Feb 01, 2016, 12:24 pm by Helmuth
Quote
Basically the NeoPixel library came first
Well, I remember how glad I was to find the FastSPI library in a time where this was the only working solution for driving programmable leds. That was the beginning of FastLED. Neopixels didnĀ“t exist on the market at this time.

Quote
is simple to install and use
Here I see no difference.

Quote
and Adafruit supports it
Please note that we have a vibrant FastLED (formerly FastSPI) community where every exotic problem is usually solved within hours.

Quote
making things simple if you are a beginner
Okay, I see that there are many tutorials out there which make the start easy.
FastLED might appear a bit overwelming at the beginning and the documentation expects that you know what you are looking for.

Quote
Note that even the Adafruits NeoPixel Uberguide recommends FastLED for advanced use.
I second that. The problem I see is that people who started with the Neopixel lib often have a hard time rewriting their animations for FastLED, because the style/syntax is quite different.



Paul__B

Nearby I'd like to build a stairslight and I'm actually not sure which library I should use.
That's easy.

We are here, taking about programmable (and contrary to the "early days" of microprocessors, reprogrammable) devices.

So there is not problem at all.

You start with one library, and then you build the same program with the other library.

Then you will know.

And the time you spend doing both is not going to be all that significant.

DrAzzy

#6
Feb 04, 2016, 06:34 am Last Edit: Feb 04, 2016, 06:36 am by DrAzzy
I use the Adafruit library because I've had problems making FastLED work in some circumstances (with non-standard AVR chips - I forget which one gave me trouble), and when I looked at the code to try to fix it, it was #define hell, and I was thoroughly unsuccessful at figuring out why it wasn't working.

For one project I took a chainsaw to the Neopixel library - https://github.com/SpenceKonde/Adafruit_NeoPixel_Static (note - none of the examples have been modified to work, only documentation that's been updated is the readme) - it saves 800-1k of flash (assuming you don't use malloc/free or things that use them (like String) elsewhere in your sketch).
ATTinyCore for x4/x5/x61/x7/x8/x41/1634/828/x313 megaTinyCore for the megaavr ATtinies - Board Manager:
http://drazzy.com/package_drazzy.com_index.json
ATtiny breakouts, mosfets, awesome prototyping board in my store http://tindie.com/stores/DrAzzy

ballscrewbob

#7
Oct 11, 2016, 03:45 pm Last Edit: Oct 11, 2016, 03:50 pm by Ballscrewbob
Re-visit

Reasons for bringing this post back up

1. I am not a developer in any sort of sense so you all know.

2. To agree that fastLED is to me at least better than Ada's offering.

3. Many of the current "fastled" libs won't run under CREATE and wondered if anyone else has had the issue and for any work arounds ?
It may not be the answer you were looking for but its the one I am giving based on either experience, educated guess, google or the fact that you gave nothing to go with in the first place so I used my wonky crystal ball.

PaulRB


ballscrewbob

#9
Oct 11, 2016, 10:48 pm Last Edit: Oct 11, 2016, 11:08 pm by Ballscrewbob Reason: Add create link and comment
The official Arduino ONLINE IDE.
It may not be the answer you were looking for but its the one I am giving based on either experience, educated guess, google or the fact that you gave nothing to go with in the first place so I used my wonky crystal ball.

PaulRB

Thanks @Ballscrewbob, was unaware of that. Might try it sometime and think about the advantages and disadvantages for me.

pert

Many of the current "fastled" libs won't run under CREATE
What exactly isn't working?


Re: FastLED vs Adafruit_NeoPixel. I recently did a project with WS2812 and ended up deciding to use FastLED instead of the Adafruit library or other options after quite a bit of research. It was a bit difficult to decide what was the best library because I was using ESP8266. I do like FastLED but found the documentation to be very hard to work with. Sometimes I really don't like Doxygen generated documentation and this was some of the worst I've ever encountered. Trying to dig through this source code was way to complicated for me. I ended up stumbling my way to what I needed by using some examples and trial and error but it was way more work than it needed to be and I get the feeling there are some awesome features of that library that I just don't know how to find the documentation for.

ballscrewbob

Hi Pert

Fastled would not work on Create DEV side so I had  a wrod on GIT and needed to make a change to the H file.
Fast ed is my prefered lib for wsw8xx strings too.
There is a good group and forum if you need any help and I got sorted out pretty quickly with what I needed.

It may not be the answer you were looking for but its the one I am giving based on either experience, educated guess, google or the fact that you gave nothing to go with in the first place so I used my wonky crystal ball.

pert

would not work on Create DEV side
What is Create DEV side?

I had  a wrod on GIT
What does that mean?

needed to make a change to the H file.
What was the change?

There is a good group and forum
Yeah, that's great, though I'm not a fan of Google+, but for me asking for help on a forum is the last resort after I've spent hours researching and trying to figure things out on my own, which I was able to do eventually. It just took longer than it could have. I suppose it's not really fair to compare the two libraries based on documentation because the Adafruit library has so much less to document but it seems to have been well done.

ballscrewbob

Sozz Pert the "development" side of create.

Typo "WORD"

Comment out a line in fastled.h that causes a stderr on create before the sketch is uploaded.

For searching for and often past what I was looking for google is a great tool. Asking questions is about learning things. Yes I will try on my own but there is always that knowledge that eludes you that somebody else has and often that other person is willing to impart to others as you yourself do so well many times a day. I guess you help out on the dev side of the IDE which means your knowledge is especially valuable to users.
It may not be the answer you were looking for but its the one I am giving based on either experience, educated guess, google or the fact that you gave nothing to go with in the first place so I used my wonky crystal ball.

Go Up