OctoWs2811

RichardFerraro

Well-known member
I am using OctoWs2811 for its fast parallel output and it works fine.
I include FastLed and use its data structures and functions that don't output to the leds.

I want to use some of the functions in FastLed, for example, fadeToBlackBy, etc.

Question: Is there a way to use these FastLed functions without handcoding them from anew?
I do not get the BasicTest_FastLED to function properly; even just setting all pixels to a constant color produces stripes.

thanks,

Richard
 
I use Teensy 4.0 with OctoWs2811 adapter. This works great when using the Octo as opposed to FastLed.

I have simplified BasicTest_FastLED to see what is going on. It outputs blue to only every 8th pixel.

#include <OctoWS2811.h>
#define USE_OCTOWS2811
#include <FastLED.h>

#define NUM_LEDS (32*8)
CRGB leds[NUM_LEDS];

void setup() {
LEDS.addLeds<OCTOWS2811,GRB>(leds,NUM_LEDS/8);
for (int i=0; i < NUM_LEDS; i++) {
leds = 0x800000;
}
FastLED.show();

}

void loop() {}
 
How do we use FastLED with OctoWS2811 while defining our own pinlist for OctoWS2811?

Yes. In Arduino, click File > Examples > OctoWS2811 >BasicTest_FastLED

Hi Paul,

This greatly simplifies connecting FastLED to OctoWS2811, thank you. However, I need to define my own pinList, similar to what you're doing here (https://github.com/PaulStoffregen/O.../examples/Teensy4_PinList/Teensy4_PinList.ino). How can I use File > Examples > OctoWS2811 >BasicTest_FastLED while using my own numPins, pinList and config like in your Teensy4_PinList.ino sketch? The line I'm referring to from Teensy4_PinList.ino is below, which doesn't exist in BasicTest_FastLED:

OctoWS2811 leds(ledsPerStrip, displayMemory, drawingMemory, config, numPins, pinList);
 
Last edited:
As far as I know, nobody has updated FastLED's code to use OctoWS2811 for pin lists. It's hard-coded for exactly 8 outputs.
 
As far as I know, nobody has updated FastLED's code to use OctoWS2811 for pin lists. It's hard-coded for exactly 8 outputs.

Thanks for the quick reply. The trouble is that we just fabbed a custom PCB with a different pinout (and 16 strings). This person has managed to use the OctoWS2811 and hook it up to FastLED manually, and was kind enough to post the code: https://www.blinkylights.blog/2021/02/03/using-teensy-4-1-with-fastled/ Do you see an issue with doing it this way?
 
I got the Teensy 4 version of FastLED’s controller working a little while back. It’s inside the main distribution; see the `COctoWS2811Controller` class in src/platforms/arm/mxrt1062/octows2811_controller.h. That's where you need to add the pin list when calling the `OctoWS2811` constructor.

Remember that when using the OctoWS2811 driver in FastLED, you need to include these three things whenever you include FastLED.h:
Code:
#include <OctoWS2811.h>
#define USE_OCTOWS2811
#include <FastLED.h>
 

Looks good. The only issue is you'll need to hard-code the pin list and number of LEDs into the FastLED code. Not really a problem for just getting your project working, just make sure to keep a backup copy of the modified library. But for publishing as part of the library, the number of LEDs and pinlist would want to become part of the template or other official API so people don't have to edit the code inside the library.
 
I got the Teensy 4 version of FastLED’s controller working a little while back. It’s inside the main distribution; see the `COctoWS2811Controller` class in src/platforms/arm/mxrt1062/octows2811_controller.h. That's where you need to add the pin list when calling the `OctoWS2811` constructor.

That's awesome Shawn, thank you!
 
Back
Top