Hi Guys
I'm trying to use a piece of C code I found:
//VARIABLES AND DEFINES HERE - NEEDED BY THE WS2812 DRIVER CODE
#define numberOfLEDs 40// total number of RGB LEDs
byte RGB[120];//take your number of LEDs and multiply by 3
The
#define numberOfLeds 40 line I was able to convert to
#define numberOfLeds b4r_ws2812b::_nleds
But been trying everything I could remember to turn the
byte RGB[120] into something that can be declared inside the B4R code without having to touch the C Code Block
This array length depends on the Number of Leds, passed in the first line, multiplied by 3, in this case, 40*3=120.
I almost always get an error complaining that the size of the array was not set to an integer constant...
b4r_ws2812b.cpp:16: error: array bound isnot an integer constant before ']' token
byte RGB[b4r_ws2812b::_ledarraysize];//take your number of LEDs and multiply by 3
Is there anyway this array can be defined inside the B4R part of the code?