Hello.
I've been forced to upgrade my christmas lights controller from a 3.2 because I need more than 8 channels.
I'm testing the 4.0 with octows2811 example with the only modification being adding a pin list for 14 channels and changing the memory buffers.
I have a few leds connected to pin 23 and it is working with ledsPerStrip at 120.
The problem I have is I need 300 ledsPerStrip. Channel 14/pin 23 isn't working when I change this value. (may or may not work for other pins but thats where my test lights are connected.
What am I doing wrong here. Thanks.
arduino reports:
Using library OctoWS2811 at version 1.5
Arduino 1.8.19.
Gavin.
I've been forced to upgrade my christmas lights controller from a 3.2 because I need more than 8 channels.
I'm testing the 4.0 with octows2811 example with the only modification being adding a pin list for 14 channels and changing the memory buffers.
I have a few leds connected to pin 23 and it is working with ledsPerStrip at 120.
The problem I have is I need 300 ledsPerStrip. Channel 14/pin 23 isn't working when I change this value. (may or may not work for other pins but thats where my test lights are connected.
What am I doing wrong here. Thanks.
arduino reports:
Using library OctoWS2811 at version 1.5
Arduino 1.8.19.
Gavin.
Code:
#include <OctoWS2811.h>
const int ledsPerStrip = 120; //this works on the 5 leds I have connected to pin 23
const int ledsPerStrip = 300; //this doesn't change the state of the 5 leds I have connected to pin 23.
DMAMEM int displayMemory[ledsPerStrip*14];
int drawingMemory[ledsPerStrip*14];
const int config = WS2811_GRB | WS2811_800kHz;
uint8_t myPinList[14] = {2, 14, 7, 8, 6, 20, 21, 5,4,11,18,19,22,23};
OctoWS2811 leds(ledsPerStrip, displayMemory, drawingMemory, config,14,myPinList);
void setup() {
leds.begin();
leds.show();
}
#define RED 0xFF0000
#define GREEN 0x00FF00
#define BLUE 0x0000FF
#define YELLOW 0xFFFF00
#define PINK 0xFF1088
#define ORANGE 0xE05800
#define WHITE 0xFFFFFF
void loop() {
int microsec = 2000000 / leds.numPixels(); // change them all in 2 seconds
// uncomment for voltage controlled speed
// millisec = analogRead(A9) / 40;
colorWipe(RED, microsec);
colorWipe(GREEN, microsec);
colorWipe(BLUE, microsec);
colorWipe(YELLOW, microsec);
colorWipe(PINK, microsec);
colorWipe(ORANGE, microsec);
colorWipe(WHITE, microsec);
}
void colorWipe(int color, int wait)
{
for (int i=0; i < leds.numPixels(); i++) {
leds.setPixel(i, color);
leds.show();
delayMicroseconds(wait);
}
}