Would using a multidimensional array help?
Below is an array with the pin numbers. I think there might be an issue looping through the arrays to make animation patterns since the shift registers use a different function than DigitalWrite to set their pins.
I have an idea for making a more multi dimensional array that will also store whether or not a pin is on the top or the bottom, what row column it is in, what pin number it is, whether is is an Arduino pin or a shift register pin.
Then all of those values could be fed into a function. That seems overly complicated and I imagine I am missing something obvious on how to go about this.
Thank you in advance.
int lightPinsTop[6][8] = {
{A0,A1,A2,A3,A4,A5,A6,A7},
{A8,A9,A10,A11,A12,A13,A14,A15},
{1,2,3,4,5,6,7,8},
{9,10,11,12,13,14,15,16},
{17,18,19,20,21,22,23,24},
{25,26,27,28,29,30,31,32}
};
int lightPinsBottom[6][8] = {
{33,34,35,36,37,38,39,40},
{41,42,43,44,45,46,47,48},
{49,50,1,2,3,4,5,6}, // These 1 - 6 are shift register pins and use a different HIGH LOW function sr.set not sure how to indicate this
{7,8,9,10,11,12,13,14}, // Shift Register Pins
{15,16,17,18,19,20,21}, // Shift Register Pins
{22,23,24,25,26,27,28} // Shift Register Pins
};