Crazymakers

Tutoriels DIY • Impression 3D • Laser • CNC • Electronique

🎨 Pixel Art LED (WS2812) avec Arduino

Voir toutes les vidéos en Electronique

Présentation

Envie de créer un affichage lumineux original ? 👀 Dans ce projet, je vous montre comment réaliser facilement un pixel art en 16x16 (ou plus) à l’aide de rubans LED WS2812 pilotés par un Arduino 🔥 🔧 Au…

Ce que vous allez apprendre

Dans cette vidéo, vous découvrirez : 🎨 Pixel Art LED (WS2812) avec Arduino.

Niveau de difficulté : Difficulté : 3/10

Description complète

Envie de créer un affichage lumineux original ? 👀

Dans ce projet, je vous montre comment réaliser facilement un pixel art en 16x16 (ou plus) à l’aide de rubans LED WS2812 pilotés par un Arduino 🔥

🔧 Au programme :

* Création de la matrice LED
* Utilisation des arrays
* Pilotage avec Arduino Pro Micro
* Résultat en pixel art animé

💡 Un projet parfait pour allier électronique et créativité !

🛒 Module LED RGB :
👉 https://goo.gl/PnvMks

📄 Schéma + sketch Arduino :
👉 http://www.crazymakers.fr/videos-youtube/un_pixel_art_avec_des_led_rvb-art--w85hIj-Quk.html

🚀 Idéal pour réaliser des affichages personnalisés et interactifs.

#WS2812 #pixelart #Arduino #LED #DIY #maker

➕ INFORMATIONS: ➕
⁉️ Catégorie: Electronique.
⏰ Temps: 2 Heures.
💪 Difficulté: 3/10.

⭐️ SOUTENIR CRAZYMAKERS ⭐️
❤️ Soutenez-nous : http://www.crazymakers.fr/don-crazymakers.html
👍 Like la vidéo pour nous aider
🔁 Partage autour de toi (ça aide énormément !)

🚀 REJOINS L’AVENTURE CRAZYMAKERS 🚀
🌐 Site officiel : http://www.crazymakers.fr
📘 Facebook : https://www.facebook.com/CrazyMakers/
📸 Instagram : https://www.instagram.com/crazymakers_fr/
🎬 YouTube : https://www.youtube.com/c/CrazyMakersFr
🎬 TikTok : https://www.tiktok.com/@crazymakers.fr

💬 UNE IDÉE OU UNE QUESTION ?
Contacte-nous en commentaire ou sur nos réseaux 👇

🔥 Merci à tous 🙌



Sketch pour Pixelart LED

/* Arduino 256 RGB LEDs Matrix Animation Frame
* Using WS2812 LED Strips
FastLED routine Created by Yvan / https://Brainy-Bits.com
Fully Optimised by Crazydoub

const long Mario[][256] PROGMEM ={
{0x252323, 0x252323, 0x252323, 0x000000, 0xff0000, 0xff0000, 0xff0000, 0xff0000,
0xff0000, 0xff0000, 0xff0000, 0xff0000, 0x000000, 0x252323, 0x252323, 0x252323,
0x252323, 0x252323, 0x252323, 0x000000, 0x5f2e11, 0x5f2e11, 0x5f2e11, 0xe0a680,
0xe0a680, 0xe0a680, 0x5f2e11, 0xe0a680, 0x5f2e11, 0x000000, 0x252323, 0x252323,
0x252323, 0x252323, 0x000000, 0x5f2e11, 0xe0a680, 0x5f2e11, 0xe0a680, 0xe0a680,
0xe0a680, 0xe0a680, 0xe0a680, 0x5f2e11, 0x5f2e11, 0x000000, 0x252323, 0x252323,
0x252323, 0x252323, 0x252323, 0x252323, 0x000000, 0xe0a680, 0xe0a680, 0xe0a680,
0xff0000, 0x4200ff, 0xff0000, 0xff0000, 0x000000, 0x252323, 0x252323, 0x252323,
0xff0000, 0xff0000, 0xff0000, 0xff0000, 0x000000, 0x000000, 0x000000, 0x252323,
0x000000, 0xff0000, 0xff0000, 0xff0000, 0xff0000, 0xff0000, 0xff0000, 0xff0000,
0xe0a680, 0x000000, 0xe0a680, 0xe0a680, 0x000000, 0x000000, 0x000000, 0x252323,
0x252323, 0x252323, 0x000000, 0xe0a680, 0xe0a680, 0xe0a680, 0x000000, 0xe0a680,
0xe0a680, 0xe0a680, 0x000000, 0xe0a680, 0xe0a680, 0xe0a680, 0x000000, 0x252323,
0x252323, 0x252323, 0x000000, 0x000000, 0x000000, 0x000000, 0x000000, 0xe0a680,
0xe0a680, 0xe0a680, 0xe0a680, 0xe0a680, 0xe0a680, 0x000000, 0x252323, 0x252323,
0x252323, 0x252323, 0x252323, 0x000000, 0x000000, 0x4200ff, 0xff0000, 0xff0000,
0x252323, 0x252323, 0x000000, 0xff0000, 0xff0000, 0xff0000, 0x4200ff, 0xff0000,
0x4200ff, 0x4200ff, 0xff0000, 0xff0000, 0xff0000, 0xff0000, 0x000000, 0x252323,
0x252323, 0x000000, 0xe0a680, 0xe0a680, 0xff0000, 0x4200ff, 0xffc600, 0x4200ff,
0x4200ff, 0x4200ff, 0x4200ff, 0xe0a680, 0xe0a680, 0xe0a680, 0x000000, 0x252323,
0x252323, 0x000000, 0xe0a680, 0xe0a680, 0x4200ff, 0x4200ff, 0x4200ff, 0x000000,
0x000000, 0x4200ff, 0x4200ff, 0x4200ff, 0x000000, 0x000000, 0x252323, 0x252323,
0x252323, 0x252323, 0x000000, 0x5f2e11, 0x5f2e11, 0x5f2e11, 0x5f2e11, 0x000000,
0x000000, 0x5f2e11, 0x5f2e11, 0x5f2e11, 0x5f2e11, 0x5f2e11, 0x000000, 0x252323,
0xff0000, 0x4200ff, 0xff0000, 0xff0000, 0xff0000, 0x000000, 0x252323, 0x252323,
0x252323, 0x000000, 0xff0000, 0xff0000, 0xff0000, 0xff0000, 0x4200ff, 0x4200ff,
0x4200ff, 0xffc600, 0x4200ff, 0xff0000, 0xe0a680, 0xe0a680, 0x000000, 0x252323,
0x252323, 0x000000, 0xe0a680, 0xe0a680, 0xe0a680, 0x4200ff, 0x4200ff, 0x4200ff,
0x000000, 0x4200ff, 0x4200ff, 0x4200ff, 0xe0a680, 0xe0a680, 0x000000, 0x252323,
0x252323, 0x252323, 0x000000, 0x000000, 0x4200ff, 0x4200ff, 0x4200ff, 0x000000,
0x000000, 0x5f2e11, 0x5f2e11, 0x5f2e11, 0x5f2e11, 0x000000, 0x252323, 0x252323,
0x252323, 0x000000, 0x5f2e11, 0x5f2e11, 0x5f2e11, 0x5f2e11, 0x5f2e11, 0x000000},
{
0x252323, 0x252323, 0x252323, 0x252323, 0x252323, 0x000000, 0xff0000, 0xff0000,
0xff0000, 0xff0000, 0xff0000, 0x000000, 0x252323, 0x252323, 0x252323, 0x252323,
0x252323, 0x252323, 0x252323, 0x252323, 0x000000, 0x5f2e11, 0x5f2e11, 0x5f2e11,
0xe0a680, 0x5f2e11, 0xe0a680, 0x5f2e11, 0x000000, 0x252323, 0x252323, 0x252323,
0x252323, 0x252323, 0x252323, 0x000000, 0x5f2e11, 0xe0a680, 0x5f2e11, 0x5f2e11,
0xe0a680, 0xe0a680, 0x5f2e11, 0x5f2e11, 0x000000, 0x252323, 0x252323, 0x252323,
0x000000, 0x000000, 0x000000, 0x000000, 0x000000, 0x000000, 0xe0a680, 0xe0a680,
0x4200ff, 0xff0000, 0xff0000, 0xff0000, 0xff0000, 0xe0a680, 0xe0a680, 0xe0a680,
0xff0000, 0xff0000, 0xff0000, 0x000000, 0x000000, 0xe0a680, 0xe0a680, 0xe0a680,
0xe0a680, 0xe0a680, 0xff0000, 0xff0000, 0xff0000, 0xff0000, 0xff0000, 0xff0000,
0xe0a680, 0xe0a680, 0x000000, 0xe0a680, 0x252323, 0xff0000, 0xff0000, 0xff0000,
0xff0000, 0xff0000, 0xe0a680, 0xe0a680, 0xe0a680, 0x000000, 0xe0a680, 0xe0a680,
0xe0a680, 0xe0a680, 0xe0a680, 0x000000, 0xe0a680, 0xe0a680, 0xe0a680, 0xff0000,
0x000000, 0xff0000, 0x000000, 0x000000, 0x000000, 0x000000, 0xe0a680, 0xe0a680,
0xe0a680, 0xe0a680, 0xe0a680, 0xe0a680, 0xe0a680, 0xff0000, 0xff0000, 0x000000,
0x000000, 0x000000, 0xff0000, 0xff0000, 0x4200ff, 0xff0000, 0xff0000, 0xff0000,
0xe0a680, 0xe0a680, 0xe0a680, 0xff0000, 0xff0000, 0xff0000, 0xff0000, 0xff0000,
0x4200ff, 0xff0000, 0xff0000, 0xff0000, 0x000000, 0x000000, 0x000000, 0x000000,
0x252323, 0x252323, 0x252323, 0x000000, 0x000000, 0x4200ff, 0x4200ff, 0x4200ff,
0x4200ff, 0x4200ff, 0x4200ff, 0x5f2e11, 0x5f2e11, 0x000000, 0x252323, 0x252323,
0x252323, 0x000000, 0x5f2e11, 0x5f2e11, 0x5f2e11, 0x4200ff, 0x4200ff, 0x4200ff,
0x000000, 0x000000, 0x000000, 0x000000, 0x5f2e11, 0x5f2e11, 0x000000, 0x252323,
0x252323, 0x252323, 0x000000, 0x000000, 0x252323, 0x252323, 0x252323, 0x252323,
0x252323, 0x252323, 0x252323, 0x252323, 0x252323, 0x252323, 0x252323, 0x252323,
0x4200ff, 0xff0000, 0xff0000, 0xff0000, 0x4200ff, 0x000000, 0x000000, 0x5f2e11,
0x5f2e11, 0x4200ff, 0x4200ff, 0xffc600, 0x4200ff, 0x4200ff, 0x4200ff, 0x4200ff,
0x4200ff, 0xffc600, 0x4200ff, 0x4200ff, 0x4200ff, 0x4200ff, 0x4200ff, 0x5f2e11,
0x5f2e11, 0x4200ff, 0x4200ff, 0x4200ff, 0x4200ff, 0x4200ff, 0x4200ff, 0x4200ff,
0x4200ff, 0x4200ff, 0x4200ff, 0x000000, 0x000000, 0x000000, 0x000000, 0x000000,
0x252323, 0x252323, 0x252323, 0x252323, 0x252323, 0x000000, 0x000000, 0x000000,
0x252323, 0x252323, 0x252323, 0x252323, 0x252323, 0x252323, 0x252323, 0x252323,
0x252323, 0x252323, 0x252323, 0x252323, 0x252323, 0x252323, 0x252323, 0x252323}};



#include
#include "FastLED.h"

#define NOMBRE_DE_LEDS 256
#define PIN_DE_L_ARDUINO 2
#define LUMINOSITE 20 // Connected to the data pin of the first LED strip

// Define the array of leds
CRGB leds[NOMBRE_DE_LEDS];




void setup() {
FastLED.addLeds(leds, NOMBRE_DE_LEDS); // Init of the Fastled library
FastLED.setBrightness(0);
Serial.begin(9600);
}

void fadeout(){
for(int i=LUMINOSITE; i>0; i--) { // Display it 8 times
FastLED.setBrightness(i);
FastLED.show();
delay(5);}
FastLED.clear();
}

void fadein(){
for(int i=0; i<=LUMINOSITE; i++) { // Display it 8 times
FastLED.setBrightness(i);
FastLED.show();
delay(5);}
}

void afficher(const long ANIMATION[][256], int NOMBRE_DE_SPRITES, int DELAI_ENTRE_SPRITES, int NB_REPETITIONS){
int k=0;
for(int i = 0; i < NOMBRE_DE_LEDS; i++) {leds[i] = pgm_read_dword(&(ANIMATION[0][i])); }
FastLED.show();
fadein();
while( k‹NB_REPETITIONS){
for(int j = 0; j < NOMBRE_DE_SPRITES; j++) { //Compteur de sprites
FastLED.clear();
for(int i = 0; i < NOMBRE_DE_LEDS; i++) {
leds[i] = pgm_read_dword(&(ANIMATION[j][i])); //Remplissage avec la sprite en cours
}
FastLED.show(); //Affichage de la sprite
delay(DELAI_ENTRE_SPRITES);
}
k++;
}
fadeout();
}

void loop() {
//afficher (Array, Nombre de sprites, délai images, répétitions);
afficher(Mario,2,500,4);
}




Commentaires YouTube

Déposer un commentaire sur YouTube

Par : @younesdc4415 le 2023-09-06T06:50:01Z

Thanks for your work

Par : @Michel.Girard le 2021-11-23T00:11:10Z

Pour commencer merci pour cette vidéo! Je n'arrive pas à trouver le Script (Use Custom Script) pour le balayage particulier dans LCD Image Converter. Merci à l'avance!

Par : @axelminet1095 le 2021-06-19T21:23:33Z

Bonjour,
Je recherche une grille et un cadre photo pour intégrer des rubans led pour l'accrocher au mur mais je ne trouve pas la grille. Ensuite il me faudrait une vitre opaque pour diffuser au mieux la lumière. Auriez-vous des liens pour cela merci d'avance.

Par : @01neoval le 2021-02-26T10:28:47Z

c'est possible utilise avec 16 Panneau LED

Par : @lmdm57 le 2020-04-02T16:56:44Z

Bonjour, j'essaie de refaire ce projet avec mon enfant mais impossible de télécharger le fichier ino sur le site. Serait-il possible de l'avoir à nouveau? Merci

Par : @ctom2 le 2019-10-31T19:58:22Z

Franchement, c’est clair, super bien expliqué !

Par : @framfpv408 le 2019-02-03T19:09:45Z

super projet je vais voir le site toute de suite

Par : @frederict2963 le 2018-11-30T04:38:11Z

Bonjour !!! Voila quelques temps que je me suis lancé sur ce petit projet ( ralenti par la commande des matrix :p)
Aucune difficulté particulière concernant le cablage ... jusqu'ici tout va bien !
Cependant est-ce moi qui suis à coté de la plaque où bien le logiciel de conversion ne fonctionne pas ?! en effet j'ai essayé une image toute noire 16x16 et voila qu'il me la convertie de toute les couleurs ...
Aurais-tu (si tu me permet de te tutoyer) une solution pour parler à cela ?
Par avance je te remercie ;)

Par : @rangirangiroa2138 le 2018-10-29T07:23:30Z

Bonjour d'abord merci pour les vidéos. Question sans doute ridicule. Moyen de programme "une grande horloge" + message en cumulant les plaques ?

Par : @michaelferrari7580 le 2018-08-28T09:07:39Z

bonjour,

as- tu testé jinx ou glediator ,si oui comment as -tu fait la liaison entre arduino et les softes( usb,wifi) ou autre ? je perd un temp fou et je n'arrive a rien
j'au juste réussi avec "ledmatrix control "mais il est un peu limité

Par : @lmdm57 le 2018-07-29T15:41:57Z

Re bonjour, peux t on régler la luminosité avec potentiomètre? Si Oui on peut l'ajouter simplement ? Faire une modif dans le programme? Merci

Par : @lmdm57 le 2018-07-24T21:39:45Z

Bonjour, très sympa cette video. 1 question combien l'alim de 5v à besoin d'ampère? MErci

Par : @GiorgioAlzora54 le 2018-07-20T02:53:28Z

Super vidéo
Merci

Par : @Sebasuchan-IDF le 2018-07-09T07:15:29Z

Super bien !
Franchement c’est épatant.

Par : @yvanbobry3563 le 2018-06-25T10:16:26Z

Super, bientôt un journal lumineux ?

Par : @Lesidéesdejean-mi le 2018-06-23T12:21:23Z

Super vidéo, à essayer impérativement👍👍👍👍

Par : @danymilka9655 le 2018-06-23T11:47:00Z

Merci pour cette vidéo !!!
Peux-tu faire un tuto sur la prog des Arduino Pro Mini ? Merci

Par : @guillaumedalle6890 le 2018-06-23T11:46:37Z

Pour programmée un arduino mini pro tu peux aussi utilisé un arduino uno
Ce projet était très intéressant et pendant les vacances qui arrive je voulais faire un truc du même style mais plus allongé donc merci pour les conseils.

Par : @Sebasuchan-IDF le 2018-06-22T18:14:19Z

Génial 👍🏼

Par : @PascalGeindreau le 2018-06-22T17:38:11Z

Superbe ! Ça donne envie de se lancer. Je vois pas le lien vers Banggood sous la vidéo 😵

Vous pouvez modifier vos choix à tout moment depuis le pied de page. Refuser n’empêche pas de consulter les tutoriels.

Fonctionnement nécessaire : sécurité du formulaire, session d’administration et mémorisation de vos préférences. Ces fonctions restent disponibles.

Choix conservés dans ce navigateur pendant 180 jours. Une désactivation recharge la page pour arrêter les services déjà chargés.