Parola_Zone_Display.ino:92:76: error: too many initializers for 'uint8_t [2] {ak

Parola_Zone_Display.ino:92:76: error: too many initializers for ‘uint8_t [2] {aka unsigned char [2]}’
Parola_Zone_Display.ino:93:78: error: too many initializers for ‘uint8_t [2] {aka unsigned char [2]}’
Fehler beim Kompilieren.

Hey guys, that´s the fault message I get trying to compile the code, if I compile it with the original:
#define MAX_DEVICES 9
#define MAX_ZONES 3
it compiles properly, problem, I got 8 devices and wanna use 2 Zones. Could you help me out as I really have no idea why it doesn´t compile.

Code_for_Parola.txt (3.52 KB)

uint8_t	inFX[MAX_ZONES] = { 0, ARRAY_SIZE(effect)/2, 2*ARRAY_SIZE(effect)/2};
uint8_t	outFX[MAX_ZONES] = { 0, ARRAY_SIZE(effect)/2, 2*ARRAY_SIZE(effect)/2 };

Three initialisers for a two element array.
The error message told you exactly what was wrong

Thanks, I´m sorry I try to understand that code, it´s a template that came with the parola libary and I´m still new to this. I changed it as follows:

uint8_t inFX[MAX_ZONES] = { 0, ARRAY_SIZE(effect)/2 };
uint8_t outFX[MAX_ZONES] = { 0, ARRAY_SIZE(effect)/2 };

based on my understanding it should divide the ARRAY_SIZE, which is set to 8 by 2 which should be 4. Yet now that the code is compiling and running on the matrixes, it only has 2x3 “areas”, where the 2 on the left are empty followed by two areas of 3 matrixes, any idea why?

Thanks in advance

With 8 devices and 2 zones, assuming that you want them to be the same size, the zones will need to be

modules 0 to 3 and 4 to 7

so that translates to

0 to (MAX_ZONES/2)-1 and (MAX_ZONES/2) to MAX_ZONES-1

Think about what you want rather than the maths and it will be clearer, always.

Do you also need to change the code that tells it where the zone boundaries are? In setup().