Arduino 8x8 Dot Led Matrix Scrolling Text Calculator

Hi,

I do it because i need a calculator for my girl friend (i'm preparing a gift for her :))

Anyway, it's easy. I attached standart code for arduino 8x8 dot matrix 7219. Then you can create your text with my excel file and copy codes from the excel, paste to the arduino code editor. But then you have to do something, because i don't finished all codes for excel file. You just copy codes from excel, paste to an editor (i'm using notepad++, it's my personal choise) and add "{" characters to all start of rows and add "}," to all end of rows. That's it!

How you can use the excel file? Very easy. When you open the excel file, you will see some texts (it's written with "1" characters. It's an example and you can change it. Then you can use "left" and "calculate" buttons for scrolling and codes. Thats it. Please try, if you cannot use, write to here, i can help you.

Have a nice day.

Share

    Recommendations

    • First Time Author

      First Time Author
    • Toys Contest

      Toys Contest
    • PCB Contest

      PCB Contest

    12 Discussions

    0
    None
    PerchE

    9 months ago

    I wrote this code in C, in my style but my code is much more complicated than yours. How did you write it so simple? For the shifting I'm developing an array of 48 bytes and another array for the carry bit. And writing and updating to the 4 displays requires me 9 for loops. And a lot of arithmetic to the arrays. Your code is much more simple and better. Can you explain to me, but you have to edit your code to do like my code, to scroll letters on 4 displays and start from blank display. Email me sheawolgnds@gmail.com

    0
    None
    ravixxx26

    2 years ago

    hey bro i need ur help ....i want the circuit diagram plssssssssssssssssssss

    m no. +919549874312(whatsapp no.)

    email id: ravianpara26@gmail.com

    thank u....

    0
    None
    abbey19

    3 years ago on Introduction

    hi ,

    this code working but not scrolling!!!!! just changing character but your video show is that scrolling how is that is the code is different??????

    1 reply
    0
    None
    onderyilmazabbey19

    Reply 3 years ago

    Hi,

    It's scrolling. I am sure about it. Please check everything again.

    0
    None
    abbey19

    3 years ago on Introduction

    unsigned char i;

    unsigned char j;

    /*Port Definitions*/

    int Max7219_pinCLK = 10;

    int Max7219_pinCS = 9;

    int Max7219_pinDIN = 8;

    unsigned char disp1[38][8]={

    {0x3C,0x42,0x42,0x42,0x42,0x42,0x42,0x3C},//0

    {0x8,0x18,0x28,0x8,0x8,0x8,0x8,0x8},//1

    {0x7E,0x2,0x2,0x7E,0x40,0x40,0x40,0x7E},//2

    {0x3E,0x2,0x2,0x3E,0x2,0x2,0x3E,0x0},//3

    {0x8,0x18,0x28,0x48,0xFE,0x8,0x8,0x8},//4

    {0x3C,0x20,0x20,0x3C,0x4,0x4,0x3C,0x0},//5

    {0x3C,0x20,0x20,0x3C,0x24,0x24,0x3C,0x0},//6

    {0x3E,0x22,0x4,0x8,0x8,0x8,0x8,0x8},//7

    {0x0,0x3E,0x22,0x22,0x3E,0x22,0x22,0x3E},//8

    {0x3E,0x22,0x22,0x3E,0x2,0x2,0x2,0x3E},//9

    {0x8,0x14,0x22,0x3E,0x22,0x22,0x22,0x22},//A

    {0x3C,0x22,0x22,0x3E,0x22,0x22,0x3C,0x0},//B

    {0x3C,0x40,0x40,0x40,0x40,0x40,0x3C,0x0},//C

    {0x7C,0x42,0x42,0x42,0x42,0x42,0x7C,0x0},//D

    {0x7C,0x40,0x40,0x7C,0x40,0x40,0x40,0x7C},//E

    {0x7C,0x40,0x40,0x7C,0x40,0x40,0x40,0x40},//F

    {0x3C,0x40,0x40,0x40,0x40,0x44,0x44,0x3C},//G

    {0x44,0x44,0x44,0x7C,0x44,0x44,0x44,0x44},//H

    {0x7C,0x10,0x10,0x10,0x10,0x10,0x10,0x7C},//I

    {0x3C,0x8,0x8,0x8,0x8,0x8,0x48,0x30},//J

    {0x0,0x24,0x28,0x30,0x20,0x30,0x28,0x24},//K

    {0x40,0x40,0x40,0x40,0x40,0x40,0x40,0x7C},//L

    {0x81,0xC3,0xA5,0x99,0x81,0x81,0x81,0x81},//M

    {0x0,0x42,0x62,0x52,0x4A,0x46,0x42,0x0},//N

    {0x3C,0x42,0x42,0x42,0x42,0x42,0x42,0x3C},//O

    {0x3C,0x22,0x22,0x22,0x3C,0x20,0x20,0x20},//P

    {0x1C,0x22,0x22,0x22,0x22,0x26,0x22,0x1D},//Q

    {0x3C,0x22,0x22,0x22,0x3C,0x24,0x22,0x21},//R

    {0x0,0x1E,0x20,0x20,0x3E,0x2,0x2,0x3C},//S

    {0x0,0x3E,0x8,0x8,0x8,0x8,0x8,0x8},//T

    {0x42,0x42,0x42,0x42,0x42,0x42,0x22,0x1C},//U

    {0x42,0x42,0x42,0x42,0x42,0x42,0x24,0x18},//V

    {0x0,0x49,0x49,0x49,0x49,0x2A,0x1C,0x0},//W

    {0x0,0x41,0x22,0x14,0x8,0x14,0x22,0x41},//X

    {0x41,0x22,0x14,0x8,0x8,0x8,0x8,0x8},//Y

    {0x0,0x7F,0x2,0x4,0x8,0x10,0x20,0x7F},//Z

    };

    void Write_Max7219_byte(unsigned char DATA)

    {

    unsigned char i;

    digitalWrite(Max7219_pinCS,LOW);

    for(i=8;i>=1;i--)

    {

    digitalWrite(Max7219_pinCLK,LOW);

    digitalWrite(Max7219_pinDIN,DATA&0x80);// Extracting a bit data

    DATA = DATA<<1;

    digitalWrite(Max7219_pinCLK,HIGH);

    }

    }

    void Write_Max7219(unsigned char address,unsigned char dat)

    {

    digitalWrite(Max7219_pinCS,LOW);

    Write_Max7219_byte(address); //address,code of LED

    Write_Max7219_byte(dat); //data,figure on LED

    digitalWrite(Max7219_pinCS,HIGH);

    }

    void Init_MAX7219(void)

    {

    Write_Max7219(0x09, 0x00); //decoding :BCD

    Write_Max7219(0x0a, 0x03); //brightness

    Write_Max7219(0x0b, 0x07); //scanlimit;8 LEDs

    Write_Max7219(0x0c, 0x01); //power-down mode:0,normal mode:1

    Write_Max7219(0x0f, 0x00); //test display:1;EOT,display:0

    }

    void setup()

    {

    pinMode(Max7219_pinCLK,OUTPUT);

    pinMode(Max7219_pinCS,OUTPUT);

    pinMode(Max7219_pinDIN,OUTPUT);

    delay(50);

    Init_MAX7219();

    }

    void loop()

    {

    for(j=0;j<38;j++)

    {

    for(i=1;i<9;i++)

    Write_Max7219(i,disp1[j][i-1]);

    delay(500);

    }

    }

    0
    None
    ibenkos

    3 years ago

    This is awesome! Nice idea, thanks for sharing :)