Skip to content

Send matrix led state model from PC to Arduino UNO and led matrix (MAX7219)

Notifications You must be signed in to change notification settings

etigui/led_matrix

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

22 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Led matrix (MAX7219) and Arduino UNO

Generate led matrix model and send it to the led matrix module through the USB.

Led matrix app

Connection schematics

The connection between the led matrix module and the Arduino UNO:

Led matrix module

Led matrix ▶ Arduino UNO

CLK (green)  ▶ D10
CS (yellow)  ▶ D11
DIN (orange) ▶ D12
GND (black)  ▶ GND
VCC (red)    ▶ 5V

Install

To send the led matrix model to the led matrix module, we must have 3 things:

  • Arduino sketch file
  • Arduino led matrix library
  • Led matrix generator

Arduino sketch

First, we must import the led matrix library to the Arduino IDE: Sketch->Import Library->Add Library. Then open and upload the Arduino sketch file (led_matrix_serial.ino) to your Arduino UNO.

Led matrix generator

With the led matrix MAX2719 program (Led_matrix.exe), you can do 2 things:

  • Send through the USB the current led model
  • Generate raw byte array from led model and paste it into Arduino sketch file

Led matrix app

Send through the USB

If the Arduino sketch file (led_matrix_serial.ino) is open and uploaded to the Arduino UNO, select the serial port attached to your Arduino and click Send. You will see the current led matrix model applied to the led matrix module.

Generate raw byte array (string)

If you don't want to set the led matrix module through the USB, open the Arduino sketch file (led_matrix.ino) to your Arduino UNO. Then, click on Copy to clipboard and paste the led matrix model "byte array string" to your Arduino sketch like the following:

byte leds[8] = {<copied byte array string>};  
byte leds[8] = {0x00,0x18,0x24,0x42,0x42,0x24,0x18,0x00}; 

Test

We can see that that we can easily change the led state with the led matrix model.

Led matrix app

Library and composant ref

led matrix library

led matrix module

Ref

An Arduino library for MAX7219 and MAX7221 Led display drivers

Arduino 8×8 LED Matrix Tutorial

Arduino tutorial: LED Matrix red 8x8 64 Led driven by MAX7219 (or MAX7221) and Arduino Uno

Android Things Port of the Arduino LedControl library for the MAX7219 LED matrix module

About

Send matrix led state model from PC to Arduino UNO and led matrix (MAX7219)

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published