SMS Based Door Lock

Hi. I’m currently working on a project that would lock doors through SMS and i’m not familiar in programming arduino.

I tried to put some codes, but there are errors in this part –

 #include <SIM900.h>
#include <sms.h>
#include <SoftwareSerial.h>


boolean started=false;

void setup ()
{
  gsmsetup();  
}


void loop ()
{
  checkSMS();
}


void gsmsetup(void)
// ---------- serial setup ----------
{
  Serial.begin(9600);
  if (gsm.begin(4800)){
    Serial.println("GSM SHIELD READY");
    started=true;  
  }
  else Serial.println("GSM SHIELD IDLE");
}

One of the error is 'gsm 'is not declared in this scope. What to do? Any help please.

What to do? Any help please.

provide us with far more information:

  • hardware used
  • link to the datasheet/manual of the hardware
  • link to the libraries used SIM900 and SMS

pseudo code to get started (this is not working code, it assumes certain functions)

#include <SIM900.h>
#include <sms.h>
#include <SoftwareSerial.h>

#define DOORLOCK  5   // pin 5 has 

void setup ()
{
  gsm.setup();  
  pinMode(DOORLOCK, OUTPUT);
}

void loop ()
{
  boolean start = gsm.checkSMS();
  if (start)
  {
    char s[] = gsm.getText();
    if (strcmp(s, "secret123") ==0)
    {
      digitalWrite(DOORLOCK, HIGH);
      delay(1000);
      digitalWrite(DOORLOCK, LOW);
    }
  }
}

I'm currently working on a project that would lock doors through SMS and i'm not familiar in programming arduino.

I can barely tie my own shoes, or walk a step, but I'm having a real tough time winning the Boston Marathon. Can you help?

Using SMS is not a trivial project. For someone that is not familiar with programming, it is a hopeless task.

For someone that is not familiar with programming, it is a hopeless task.

But PaulS, that is why he /she asked the forum for help. BTW OP said: i'm not familiar in programming arduino. so there is hope

"This journey of a thousand miles begins with a single step" - Lao Tzu

OP said: i'm not familiar in programming arduino. so there is hope

Programming an Arduino is no different from programming any other computer. There are APIs to call, and results to collect. There are hardware limits to respect.

Whenever I read "i'm not familiar in programming arduino", the period in the statement is almost always one word too far in the sentence. I assumed that it was true in this case, too.

imho everyone can learn to program, and yes not everyone will be at Olympic level.

imho everyone can learn to program, and yes not everyone will be at Olympic level.

I don't disagree. My only point was that sending SMS messages is not a beginner project. Blinking LEDs is. Build on that experience to do more complex things as you build an understanding of the hardware, of C++, of reading library documentation, etc.

Just like winning the Boston Marathon is not a suitable goal for a toddler learning to tie shoes.