lo he subido tal cual lo escribiste y me sale este mensaje de error
Arduino:1.8.7 (Windows 7), Tarjeta:"SparkFun Pro Micro, ATmega32U4 (5V, 16 MHz)"
12potes_14_botones:27:24: error: 'Npots' was not declared in this scope
const byte totalPots = Npots + muxPots;
^
12potes_14_botones:30:24: error: size of array 'potCState' is not an integral constant-expression
int potCState[totalPots] = {0}; // estado atual de la puerta analogica
^
12potes_14_botones:31:24: error: size of array 'potPState' is not an integral constant-expression
int potPState[totalPots] = {0}; // estado previo de la puerta analogica
^
12potes_14_botones:33:26: error: size of array 'lastCcValue' is not an integral constant-expression
int lastCcValue[totalPots] = {0};
^
12potes_14_botones:40:30: error: size of array 'pTime' is not an integral constant-expression
unsigned long pTime[totalPots] = {0}; // tempo armazenado anteriormente
^
12potes_14_botones:41:30: error: size of array 'timer' is not an integral constant-expression
unsigned long timer[totalPots] = {0}; // armazena o tempo que passou desde que o timer foi zerado
^
exit status 1
'Npots' was not declared in this scope
Este reporte podría tener más información con
"Mostrar salida detallada durante la compilación"
opción habilitada en Archivo -> Preferencias.