Hello everyone, i have a small question to whoever will be so kind to answer me :). i’m new to the led strips and led matrix technology but quite familiar with a lot of microcontrollers. What i am really missing is experience in choosing the correct LED strips. My project will be based on ESP32 and will have to pilot roughly 14 led strips (indipendently if possible). The total length of the strips will be roughly 6 meter (almost a rectangle surface 340mm x 160mm + 1m strip).
6 meter starts to costs a lot so i’m wondering what could be a good general purpose strips.
I guess this would be good https://www.adafruit.com/product/2842 (but is it supported?) or this https://www.adafruit.com/product/2240
The project will use every kind of possible effects and it must be IP65
My favourites are 5V APA102’s (DotStars), however, if they’re wired independently, then all bets are off. For independent wiring, you may be better off with the 5V WS2812’s (NeoPixels).
@Andrew_Tuline What do you mean with all bets are off?
Probably that wired indipedently is due to my scarse knowledge. Can i connect 1 SPI pin to all the strips even if they are cutted? Moreover is there a suggest powerbank that can output 5V@3A for example?
WS2812’s have a single combined clock/data pin. It runs at a pretty slow frequency, but FastLED supports connecting multiple strips to multiple pins (pretty cool). This comes at the disadvantage of disabling IRQ’s on the type of Arduino’s that I use; namely the Nano.
APA102’s, have separate clock and data pins and run at a much higher frequency. IRQ’s are not disabled, so I can use other libraries, such as InfraRed. FastLED does not support the multiple strip/pin arrangement that you get with the WS2812’s.
That being said, I’ve cut strips and then connected them via wires, i.e. in order to create a six sided star.
Disclaimer: I only use Nano’s, so it might work differently on another chipset.
so for the APA102 you are using 1 SPI (2 cables) even if you have 6 (or more) strips?
Both types are transmit-only from the microcontroller to the LEDs. The microcontroller does not “know” if you have connected 1 strip or 6 of them to the same data signal. If you have a 6 sided cube and you want all 6 sides to display the same, you can just connect them all to the same data.
So to achieve indipendency with an SPI led i need to connect all the strips in series so that they are treated as one, hence i don’t “mirror” them?
Instead with 1 pin pwm led i can connect them separately?
The RGBW strips you linked to are not supported by FastLED yet.
The most popular are WS2812B style or APA102C.
I use SK9822s which are very similar to APA102Cs, and they work well with an ESP32.
So far I’ve only used two strips on one ESP32, but it should be easy to run many more.
I always buy my strips from Ray Wu
http://s.aliexpress.com/B3mQjaQv?fromSns
Waooo those prices are way better, let me get it clear then:
- WS2812B are PWM-based led
- APA102C/SK9822s are SPI-based led
Can SPI-based be driven with a PWM? Just a question because FastLED code for ESP32 is not that frequent so i’m missing sketches and examples of pins configurations
@Massimiliano_Gilli not sure you are using the term PWM correctly. Some pins on microcontrollers can be used as PWM, but that is not how you drive the “smart” LED strips.
The two major differences between apa102 and ws2812 are:
- apa102 uses 4 wires (two for power and ground, one for data, one for clock signal), while ws2812b uses 3 wires (power, ground, data)
- apa102 is faster
You can use six strips of ws2812b sequentially, just connect “data out” of the first strip (middle contact at the end of it) to “data in” of the second one (middle contact at the begining of it), and so on. From the software point of view, it will be just one long strip.
Those four wires are the SPI or they can be any GPIO pins?
I mean what does the term Hardware SPI / Software SPI that sometimes i see? On an ESP32 can i potentially use whichever pin i like or only those who are SPI enabled? If i connect the 2 data pins on subsequent APA102 strips i should be able to achieve the same right? The strips must be cutted for geometric reason but from what i’ve seen in the software i can break a strips into two sub-strips
In my experience, hardware SPI is not a must (also see https://github.com/FastLED/FastLED/wiki/SPI-Hardware-or-Bit-banging).
Yes, you can chain apa102 strips to each other.
Still don’t know what you mean by PWM-based. All these LEDs use PWM internally to control brightness (and this has nothing to do with ESP32 PWM which can be used to control “non-smart” LED or LED strips brightness)