#include <LedControl.h>
// LedControl(DIN, CLK, CS, number of devices)
LedControl lc = LedControl(11, 13, 10, 1);
void setup() {
lc.shutdown(0, false); // Wake up the MAX7219
lc.setIntensity(0, 8); // Brightness (0–15)
lc.clearDisplay(0); // Start clean
}
void loop() {
for (byte riga = 0; riga < 8; riga++) {
lc.setLed(0, riga, 7, true);
}
for (byte col = 0; col < 8; col++) {
lc.setLed(0, 0, col, true);
}
}