Tuesday 12 February 2019

Wiring MAX7219 on 8 Bit 7 Segment Digital LED Tube Display

Yet another illustration guide, how to wire the MAX7219 on 8 Bit 7 Segment Digital 
LED Display driven by MAX7219. The MAX7219 is an integrated serial input output common-cathode display driver which is connected to microprocessor or microcontroller along with the 8 bit 7 segment digital LED display. This module you also place the 
LED Graph display LED or 64 separated LED. Includes an on chip type B BCD 
encoder a multi-channel scanning loop, segment WORD driver, and also an 
8×8 static RAM that stores each data. This chip is only one external register 
can be used to set the current of each LED segment.

Durable-MAX7219-8-Bit-7-Segment-Red-LED-Display-Tube-Module-Board-For-Arduino-2212

The MAX7219 has integrates a convenient four wire serial interface that can be 
used to all micro-controller, microprocessor. Each on-chip data can be addressed 
in the update without rewriting all display, and also allows you to select each data 
encoding or no-coding.
The entire module device includes a 150μA low power shut off mode, analog and
 digital brightness control, scan limit register allows you to display 1-8 bit data, 
and LED light detection mode.
Feature:
0.36 inch
Common cathode
Only need three IO ports can drive 8 bit digital tube
The module compatible of 5V / 3.3V microcontroller (51 / AVR / STM3) and Raspberry Pi

Schematics Diagram





























Code










1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
/*
14CORE TEST CODE 8BIT LED TUBE
http://www.14core.com
pin 12 is connected to the DataIn
pin 11 is connected to the CLK
pin 10 is connected to LOAD
*/
#include "LedControl.h"
LedControl lc=LedControl(12,11,10,1);
void setup()
{
Serial1.begin(9600);
// Initialize the MAX7219
Serial.write("14CORE TEST CODE FOR LED MAX7219 LED TUBE");
lc.shutdown(0,false); // To Enable the Display
lc.setIntensity(0,15); // To set the brightness level (0 is min, 15 is max)
lc.clearDisplay(0); // To Clear the display register
//}
}
void loop()
{
// test afisare un anumit text
lc.clearDisplay(0); // To Clear the display register
lc.setDigit(0,7,2, false);
// To display the 2 first column on the left (column 7)
lc.setDigit(0,6,5, true); // To display a 5 column 6 and decimal point
lc.setDigit(0,5,4, false); // To display a 4 column 5
lc.setRow(0,4,B1001110);
lc.setDigit(0,2,3, false); // To show the 5 on 2nd
lc.setDigit(0,1,7, false); // To Place a 0 in the column 1
lc.setRow(0,0,B0110111);
delay(3000);
// fac alt text
lc.clearDisplay(0); // Clear display register
lc.setDigit(0,7,1, false);
// To display a 1 at the first column on the left (column 7)
lc.setDigit(0,6,2, false); // To display a 2 column 6 and decimal point
lc.setRow(0,5,B00000001);
lc.setDigit(0,4,4, false); // display a "4" in column 4
lc.setDigit(0,3,2, false); // display a "2" in column 3
lc.setRow(0,2,B00000001);
lc.setDigit(0,1,3, false); // To display a 3 column 1
lc.setDigit(0,0,6, false); // 6 show a first hand column, column 0
delay(3000);
// fac inca un text
lc.clearDisplay(0); // To Clear the display register
lc.setRow(0,6,B01100010); // "n"
lc.setRow(0,5,B00100000); // "i"
lc.setRow(0,4,B01110011); // "q"
lc.setRow(0,3,B00000001);  
lc.setRow(0,2,B01000010); // "r"
lc.setRow(0,1,B01100011); // "o"  
delay(3000); // Delay 3 Seconds
}

No comments: