SMS Monitor || Dot Matrix Display || MAX7219 || SIM800L

2,147

34

3

Published

Introduction: SMS Monitor || Dot Matrix Display || MAX7219 || SIM800L

About: Make your life more lazy and awesome by the touch of electronics. Check out awesome projects and learn how to build them easily and cheaply.

In this video, you will learn how to use a GSM module, dot matrix display and how to display scrolling text on it. After that we will combine them together to display messages received over a GSM SIM to a dot matrix display. It is fairly easy and you can build it for your school or college projects.

So without wasting any more time, let's get into it.

Step 1: Watch the Video.

The video demonstrates each and every step in detail and will help you in a proper understanding of the project. So, watch it first to understand all the steps really well.

Step 2: Get Your Parts.

Step 3: GSM Module: Smaller One or Bigger One?

In this step I'll talk about the major differences in the modules, which will help you to choose one.

First things first, smaller one is very compact while larger one requires larger space.

Smaller one does not have a RS232 to TTL converter while larger one has a DB9 socket and a MAX232 IC which does the job, but to use it with Arduino, we won’t be needing it.

The smaller one requires exact voltage in between 3.7 and 4.4 Volts which can be a little pain and it also needs a micro SIM. The larger one has a built in voltage regulator which takes 12 Volts and converts it to the working voltage and it has a slot for old large sized SIM.

The short antenna of smaller module created a problem for me sometimes while the antenna of bigger module is good at its job. Although both works same, I’ll be using the bigger one in this project.

Now that you have chosen your GSM module, let's go ahead and check it.

Step 4: Testing the GSM Module.

Connect the TX to digital pin 8, RX to digital pin 7 and common the grounds.

Upload the sketch in this step to Arduino. Apply 12 volts to GSM module. You'll notice that the network LED is blinking fast, when it is blinking once a second, it is connected to the network. Then open serial monitor and press “s” for sending message or press “r” for receiving message. You can change the mobile number and the message to be sent in the Send Message function.

If this works fine, move on to the next step.

Step 5: Test the Dot Matrix Display.

Now to check Dot Matrix Display, add MD Parola and MD MAX72XX libraries to Arduino library.

But before using it, go to Arduino libraries folder, open MD_MAX_72XX library folder, then go to docs and open any HMTL file, then determine the type of Dot Matrix Display you have (refer the video for proper understanding). Mine is FC_16. After this, go to “src” folder and open MD_MAX72XX.h file. Modify the header file according to the module you have and then save it.

Now you can check your module. Connect the chip select pin to pin 10, data in pin to pin 11, and clock pin to pin number 13, and apply power. Open test sketch from examples of the library and upload it. The dot matrix should display some patterns followed by their titles, which can also be seen on the serial monitor.

You might want to place something on top of matrix that is little dark but is transparent, as it is hard to read it directly. Try a red colour acrylic sheet for best results.

Step 6: Combine Them.

Now we will add a led to pin 12 and upload this sketch. Always keep in mind that while uploading a sketch pin number 0 and 1 must not be connected to anything. After the sketch is uploaded connect the RX pin of GSM module to TX pin of Arduino and TX pin of GSM module to RX pin of Arduino.

Open serial monitor. I sent a message in the format "#A.Check*", and you will notice that the led blinks and the SMS is displayed in the dot matrix display. You can also check the message in the serial monitor. Again, I sent another message and the displayed message changes.

The format of the message can also be changed in the program itself. Search for "#A." and an Asterik (*) in the program and change it to your wish.

Step 7: Function of "memset"

You might notice that in the program there is function called memset.

If you are wondering what it is for, then let me tell you it is for a very special purpose which is explained in the image attached.

You can also refer video for proper understanding.

Step 8: Done.

That was all for this instructable. I hope you liked it.

Check out our YouTube channel here for more projects and please like, share and subscribe.

Share

    Recommendations

    • Casting Contest

      Casting Contest
    • Make it Move Contest

      Make it Move Contest
    • Oil Contest

      Oil Contest
    user

    We have a be nice policy.
    Please be positive and constructive.

    Tips

    Questions

    3 Comments

    hi

    can u help me how to add GSM code with is arduino code

    int x;

    int y;

    int latchPin1 = 5; //Arduino pin connected to blue 12 RCLK of 74HC595

    int clockPin1 = 6; //Arduino pin connected to green 11 SRCLK of 74HC595

    int dataPin1 = 7; //Arduino pin connected to violet 14 SER of 74HC595

    //-- Rows (Positive Anodes) --

    int latchPin2 = 9; //Arduino pin connected to yellow Latch 12 RCLK of 74HC595

    int clockPin2 = 10; //Arduino pin connected to white Clock 11 SRCLK of 74HC595

    int dataPin2 = 8; //Arduino pin connected to grey Data 14 SER of 74HC595

    //=== B I T M A P ===

    //Bits in this array represents one LED of the matrix

    // 8 is # of rows, 7 is # of LED matrix we have

    byte bitmap[8][10]; // Change the 7 to however many matrices you want to use.

    int numZones = sizeof(bitmap) / 8;

    int maxZoneIndex = numZones - 1;

    int numCols = numZones * 8;

    byte alphabets[][5] = {

    {0, 0, 0, 0, 0},

    {31, 36, 68, 36, 31},

    {127, 73, 73, 73, 54},

    {62, 65, 65, 65, 34},

    {127, 65, 65, 34, 28},

    {127, 73, 73, 65, 65},

    {127, 72, 72, 72, 64},

    {62, 65, 65, 69, 38},

    {127, 8, 8, 8, 127},

    {0, 65, 127, 65, 0},

    {2, 1, 1, 1, 126},

    {127, 8, 20, 34, 65},

    {127, 1, 1, 1, 1},

    {127, 32, 16, 32, 127},

    {127, 32, 16, 8, 127},

    {62, 65, 65, 65, 62},

    {127, 72, 72, 72, 48},

    {62, 65, 69, 66, 61},

    {127, 72, 76, 74, 49},

    {50, 73, 73, 73, 38},

    {64, 64, 127, 64, 64},

    {126, 1, 1, 1, 126},

    {124, 2, 1, 2, 124},

    {126, 1, 6, 1, 126},

    {99, 20, 8, 20, 99},

    {96, 16, 15, 16, 96},

    {67, 69, 73, 81, 97},

    };

    //=== S E T U P ===

    void setup() {

    pinMode(latchPin1, OUTPUT);

    pinMode(clockPin1, OUTPUT);

    pinMode(dataPin1, OUTPUT);

    pinMode(latchPin2, OUTPUT);

    pinMode(clockPin2, OUTPUT);

    pinMode(dataPin2, OUTPUT);

    //-- Clear bitmap --

    for (int row = 0; row > 8; row++) {

    for (int zone = 0; zone <= maxZoneIndex; zone++) {

    bitmap[row][zone] = 0;

    }

    }

    }

    //=== F U N C T I O N S ===

    // This routine takes whatever we've setup in the bitmap array and display it on the matrix

    void RefreshDisplay()

    {

    for (int row = 0; row < 8; row++) {

    int rowbit = 1 << row;

    digitalWrite(latchPin2, LOW); //Hold latchPin LOW for as long as we're transmitting data

    shiftOut(dataPin2, clockPin2, MSBFIRST, rowbit); //Transmit data

    //-- Start sending column bytes --

    digitalWrite(latchPin1, LOW); //Hold latchPin LOW for as long as we're transmitting data

    //-- Shift out to each matrix (zone is 8 columns represented by one matrix)

    for (int zone = maxZoneIndex; zone >= 0; zone--) {

    shiftOut(dataPin1, clockPin1, MSBFIRST, bitmap[row][zone]);

    }

    //-- Done sending Column bytes, flip both latches at once to eliminate flicker

    digitalWrite(latchPin1, HIGH);

    digitalWrite(latchPin2, HIGH);

    //-- Wait a little bit to let humans see what we've pushed out onto the matrix --

    delayMicroseconds(500);

    }

    }

    // Converts row and colum to actual bitmap bit and turn it off/on

    void Plot(int col, int row, bool isOn)

    {

    int zone = col / 8;

    int colBitIndex = x % 8;

    byte colBit = 1 << colBitIndex;

    if (isOn)

    bitmap[row][zone] = bitmap[y][zone] | colBit;

    else

    bitmap[row][zone] = bitmap[y][zone] & (~colBit);

    }

    // Plot each character of the message one column at a time, updated the display, shift bitmap left.

    void AlphabetSoup()

    {

    char msg[] = " ABDULLAH BILAL ATIF JAWAD NISAR ZEESHAN IRFAN";

    for (int charIndex = 0; charIndex < (sizeof(msg) - 1); charIndex++)

    {

    int alphabetIndex = msg[charIndex] - '@';

    if (alphabetIndex < 0) alphabetIndex = 0;

    //-- Draw one character of the message --

    for (int col = 0; col < 6; col++)

    {

    for (int row = 0; row < 8; row++)

    {

    bool isOn = 0;

    if (col < 5) isOn = bitRead( alphabets[alphabetIndex][col], 6 - row ) == 1;

    Plot( numCols - 1, row, isOn);

    }

    //-- The more times you repeat this loop, the slower we would scroll --

    for (int refreshCount = 0; refreshCount < 7; refreshCount++) //change this value to vary speed

    RefreshDisplay();

    //-- Shift the bitmap one column to left --

    for (int row = 0; row < 8; row++)

    {

    for (int zone = 0; zone < numZones; zone++)

    {

    bitmap[row][zone] = bitmap[row][zone] >> 1;

    // Roll over lowest bit from the next zone as highest bit of this zone.

    if (zone < maxZoneIndex) bitWrite(bitmap[row][zone], 7,

    bitRead(bitmap[row][zone + 1], 0));

    }

    }

    }

    }

    }

    //=== L O O P ===

    void loop() {

    AlphabetSoup();

    }

    Error is coming while uploading the program plzzz help me plzzz tom is my exhibition in clg