1

I'm testing SIM800L GSM module with Arduino UNO and module is blinking 3 times every 15 seconds or sometime every 45 seconds. Why this is happening? In serial monitor it shows Message Sent Successfully! but I'm not getting any message.I tried with multiple numbers. Still not getting any message.

I have tested several codes which shows outputs of AT commands. Nothing was working. Power supply is 5V 5A.

/*    
 *   Author@ExploreEmbedded 
 *   Example to Send messages Interactively using GSM Sim800L
 *    
 *   LIBRARY CREDITS:
 *   Thanks to Cristian Steib([email protected]) for the library.
 *    
 *  
 *     
 *      PINOUT: 
 *        _____________________________
 *       |  ARDUINO UNO >>>   Sim800L  |
 *        -----------------------------
 *            GND      >>>   GND
 *        RX  10       >>>   TX    
 *        TX  11       >>>   RX
 *       RESET 2       >>>   RST 
 *                 
 *  
*/

#include <Sim800L.h>
#include <SoftwareSerial.h> //is necesary for the library!! 
Sim800L Sim800L;  //to declare the library
char text[161]=""; //buffer to store message
char number[11]=""; //phone number to send message
int cnt;
bool error; //to catch the response of sendSms

void setup(){
    Sim800L.begin(); // initializate the library. 
    Serial.begin(9600);
}

void loop(){

      //Read the Number
      Serial.print("\nEnter 10 digit Phone Number:");
      while(Serial.available()<=0); 
      cnt = Serial.readBytesUntil('\n',number, 11);
      number[cnt] = '\0';
      Serial.println(number);

      //clear the serial input buffer so that no typed characters are pending

      delay(1000); //delay required before clearing the input buffer
      while(Serial.available()>0) //clear buffer
      {
        Serial.read();
      }


      //Read the Message to be sent
      Serial.print("Enter Message:");
      while(Serial.available()<=0); 
      cnt = Serial.readBytesUntil('\n',text, 160);
      text[cnt] = '\0';
      Serial.println(text);
      delay(1000);

      while(Serial.available()>0) //clear buffer
      {
        Serial.read();
      }

      //Send the message and display the status
      error = Sim800L.sendSms(number,text);
      if(error)
      Serial.println("Error Sending Message");
      Serial.println("Message Sent Successfully!");


}

1 Answer 1

1

I found what's happening. Module was shutdown due to over voltage.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.