🛠 Apprivoiser la matrice LED 12x8 intégrée

Arduino UNO R4 WiFi · debutant · Schéma : IMG-uno-r4-wifi-debutant-2-ur4wifi-matrice-led-12x8.svg — gros plan sur la matrice LED 12x8 de l'UNO R4 WiFi, grille annotée colonnes 0 à 11 et lignes 0 à 7, flèches vers les broches 12 à 23 (colonnes) et GPIO internes 24 à 31 (lignes).

Objectives

Control the card's signature: a 96-LED matrix (12 columns × 8 rows) soldered onto the board, driven via multiplexing directly by the RA4M1 — the columns are connected to pins 12 to 23 (pins A0 to A3 are shared with the matrix) and the rows to GPIOs 24 to 31, which are not exposed on the connectors. You will light up columns, understand bit masking, and then display an animation.

Hardware

Complete code

#include "Arduino_LED_Matrix.h"

ArduinoLEDMatrix matrix;

void setup {
  matrix.begin;
}

void loop {
  // Balayage : une colonne allumée qui se déplace.
  for (uint8_t col = 0; col < 12; col++) {
    matrix.beginFrame;
    for (uint8_t c = 0; c < 12; c++) {
      // Chaque setColumn reçoit un octet = masque des 8 lignes,
      // bit de poids faible = ligne du bas.
      matrix.setColumn(c, c == col ? B11111111 : B00000000);
    }
    matrix.show;
    delay(80);
  }
}

The official Arduino_LED_Matrix library also provides matrix.loadFrame(...) for 32-bit encoded frames, and the AnimationEngine class with ready-to-use modes (SCROLLING, THROBBING, BLINKING). To draw without coding, the online editor Arduino Labs (labs.arduino.cc, LED Matrix tool) generates the frame arrays to paste into the sketch.

Expected verification

A vertical bar sweeps across the matrix from left to right in a loop. Test B10000001 instead of B11111111: only the first and last bits light up, confirming bit-by-bit reading (LSB = bottom row).

Common errors

Other tutorials for this board

Code examples for this board

← Back to the board 🛠 All tutorials