lingeshbarani / gsm-shield-arduino

Automatically exported from code.google.com/p/gsm-shield-arduino
0 stars 0 forks source link

GSM problem connecting #64

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
GSM Shield testing.
ERROR: SIM900 doesn't answer. Check power and serial pins in GSM.cpp

status=IDLE

I have the power supply connected 10V 2A.
I have the libraries downloaded and installed.
i have the tx and rx connector pins in 2 and 3.

cant get the shield to communicate.

I'm using arduino uno R3
Icomsat 1.1 / SIM 900
arduino 1.0.1.

Can anybody get me a solution to this problem?

Thomas

Original issue reported on code.google.com by tomoc1...@gmail.com on 22 Feb 2013 at 10:54

GoogleCodeExporter commented 8 years ago
I have same problem. I'm using a MEGA 2560 board and the EFCOM 1.2

Please, help us with this issue.

Regards,

Samuel

Original comment by samuel.r...@flash-global.com on 28 Feb 2013 at 6:33

GoogleCodeExporter commented 8 years ago
Dear,
I had this problem, but the cause of the problem was that the shield was 
already with the serial baudrate preconfigured on (19200), was enough so I do 
the same configuration in code so that the Arduino could communicate with the 
shield.

Module EFCom-Pro - Elecfreaks - http://goo.gl/cH0xX
Freduino UNO - Rev1.8 - Elecfreaks - http://goo.gl/H38S5

Arduino IDE - 1.0.3

code:

/ / Serial connection.
   Serial.begin (19200);
   Serial.println ("GSM Shield testing.");
   / / Start configuration of shield with baudrate.
   / / For http raccomanded uses is to use 4800 or slower.
   if (gsm.begin (19200)) {
     Serial.println ("\ nstatus = READY");
     started = true;
   }

Original comment by mkmt...@gmail.com on 3 Mar 2013 at 11:27

GoogleCodeExporter commented 8 years ago
Normally the lib has the auto-baudrate.
However to determine which is the problem (hardware or software) you should 
de-comment line 20 on GSM.h
from:
//#define DEBUG_ON
to:
#define DEBUG_ON

and post the output.
In this way it's possible to say if it is an hardware problem or software (like 
baudrate)

Original comment by martines...@gmail.com on 8 Mar 2013 at 10:45

GoogleCodeExporter commented 8 years ago
Please, try -  if (gsm.begin (2400)) 

worked for me

Thanks

Sérgio

Original comment by sergioli...@gmail.com on 13 Mar 2013 at 4:57

GoogleCodeExporter commented 8 years ago
I have the same problem with arduino mega and SIM908 modul. I tested the 
hardware by listening to the RX and TX pins on the shield, and the modul sends 
the right command responds with OK to AT and says its ready, but the serial 
monitor of the arduino gives me the error:
GSM Shield testing.
ERROR: SIM900 doesn't answer. Check power and serial pins in GSM.cpp

status=IDLE

So, the arduino doesnt process that respond well. I tryed to play with baud 
rates as some suggestions said above, but it didnt help. Any would appreciate 
any adivce!

Original comment by scoobyc...@gmail.com on 9 Apr 2013 at 6:05

GoogleCodeExporter commented 8 years ago
hello I got a seedstudio gprs that has sim900 i used sscom32e to send commands 
after i used the gsm library (that it actually worked) the sscom32e that was 
working at 19200 baudRate is no working anymore, any idea?

Original comment by enriques...@gmail.com on 13 Apr 2013 at 3:59

GoogleCodeExporter commented 8 years ago
For problem not linked to this library plase use Arduino forum!
Marco

Original comment by martines...@gmail.com on 13 Apr 2013 at 4:41

GoogleCodeExporter commented 8 years ago
I have the EfComPro, I can't connect the board by serial communication, someone 
made that?

Original comment by edco...@gmail.com on 12 Jun 2013 at 4:40

GoogleCodeExporter commented 8 years ago
This issue section is not longer supported.
Please check the support page www.gsmlib.org 

Original comment by martines...@gmail.com on 6 Jul 2013 at 11:26

GoogleCodeExporter commented 8 years ago
This issue section is not longer supported.
Please check the support page www.gsmlib.org 

Original comment by martines...@gmail.com on 6 Jul 2013 at 11:27

GoogleCodeExporter commented 8 years ago
I need help, i have an Arduino Mega 2560  and a EFCOM PRO V 1.0 
(http://www.elecfreaks.com/wiki/index.php?title=EFCom_Pro_GPRS/GSM_Module), and 
i need only to send sms with an alert. My question is if i can supply the power 
from the mega to the EFCOM pro v1.0 even though it says that in a transmission 
brush, it could demand 2 Amperes?

Original comment by julianis...@gmail.com on 27 Oct 2013 at 5:01

GoogleCodeExporter commented 8 years ago
The correct is to energize the GSM-shield by a source external enrgía since
it requires a higher amperage, the times I tried using it with the feed
coming from the Arduino Uno itself, it lost the connection to the GPRS
network .

Original comment by mkmt...@gmail.com on 27 Oct 2013 at 5:20

GoogleCodeExporter commented 8 years ago
MEGA2560 does not support softwareserial on pins 2 + 3! you can use RX1/TX1 on 
18/19 without software-serial.

Original comment by david.sp...@gmail.com on 9 Jan 2014 at 12:04

GoogleCodeExporter commented 8 years ago
Dear please help me.

After loading following code

#include <SoftwareSerial.h>

// EN: String buffer for the GPRS shield message
String msg = String("");
// EN: Set to 1 when the next GPRS shield message will contains the SMS message
int SmsContentFlag = 0;
//control pins of relay.
int relay_a=4;
int relay_b=5;
int relay_c=6;
int relay_d=7;

// EN: Code PIN of the SIM card (if applied)
//String SIM_PIN_CODE = String( "XXXX" );

void setup()
{
  Serial.begin(9600);                 // the GPRS baud rate
  // Initialize  PINs
  pinMode( 4, OUTPUT ); 
  pinMode( 5, OUTPUT ); 
  pinMode( 6, OUTPUT ); 
  pinMode( 7, OUTPUT ); 
  digitalWrite( 4, LOW ); 
  digitalWrite( 5, LOW ); 
  digitalWrite( 6, LOW );
  digitalWrite( 7, LOW );
 Serial.println( "AT+CMGF=1" ); 
 delay(6000);
}

void loop()
{
    char SerialInByte;
    if(Serial.available())
    {       
        SerialInByte = (unsigned char)Serial.read();
       delay(5);

        // -------------------------------------------------------------------
        // EN: Program also listen to the GPRS shield message.
        // -------------------------------------------------------------------
       // EN: If the message ends with <CR> then process the message
        if( SerialInByte == 13 ){
          // EN: Store the char into the message buffer
          ProcessGprsMsg();
         }
         if( SerialInByte == 10 ){
            // EN: Skip Line feed
         }
         else {
           // EN: store the current character in the message string buffer
           msg += String(SerialInByte);
         }
     }   
}
// EN: Make action based on the content of the SMS. 
//     Notice than SMS content is the result of the processing of several GPRS 
shield messages.
void ProcessSms( String sms ){

  if( sms.indexOf("ona") >= 0 ){
    digitalWrite( relay_a, HIGH );
  }
   if( sms.indexOf("onb") >= 0 ){
    digitalWrite(  relay_b, HIGH );
  }
   if( sms.indexOf("onc") >= 0 ){
    digitalWrite(  relay_c, HIGH );
  }
  if( sms.indexOf("ond") >= 0 ){
    digitalWrite(  relay_d, HIGH );
  }
  if( sms.indexOf("offa") >= 0 ){
    digitalWrite(  relay_a, LOW );
  }
  if( sms.indexOf("offb") >= 0 ){
    digitalWrite(  relay_b, LOW );
  }
  if( sms.indexOf("offc") >= 0 ){
    digitalWrite(  relay_c, LOW );
  }
  if( sms.indexOf("offd") >= 0 ){
    digitalWrite(  relay_d, LOW );
  }
}
// EN: Request Text Mode for SMS messaging
void GprsTextModeSMS(){
  Serial.println( "AT+CMGF=1" );
}

void GprsReadSmsStore( String SmsStorePos ){
  Serial.print( "AT+CMGR=" );
  Serial.println( SmsStorePos );
}

// EN: Clear the GPRS shield message buffer
void ClearGprsMsg(){
  msg = "";
}

// EN: interpret the GPRS shield message and act appropiately
void ProcessGprsMsg() {
  if( msg.indexOf( "Call Ready" ) >= 0 ){
   //  Serial.println( "*** GPRS Shield registered on Mobile Network ***" );
     GprsTextModeSMS();
  }

  // EN: unsolicited message received when getting a SMS message
  if( msg.indexOf( "+CMTI" ) >= 0 ){
   //  Serial.println( "*** SMS Received ***" );
     // EN: Look for the coma in the full message (+CMTI: "SM",6)
     //     In the sample, the SMS is stored at position 6
     int iPos = msg.indexOf( "," );
     String SmsStorePos = msg.substring( iPos+1 );
   //  Serial.print( "SMS stored at " );
  //   Serial.println( SmsStorePos );     
     // EN: Ask to read the SMS store
     GprsReadSmsStore( SmsStorePos );
  }

  // EN: SMS store readed through UART (result of GprsReadSmsStore request)  
  if( msg.indexOf( "+CMGR:" ) >= 0 ){
    // EN: Next message will contains the BODY of SMS
    SmsContentFlag = 1;
    // EN: Following lines are essentiel to not clear the flag!
    ClearGprsMsg();
    return;
  }

  // EN: +CMGR message just before indicate that the following GRPS Shield message 
  //     (this message) will contains the SMS body 
  if( SmsContentFlag == 1 ){
 //   Serial.println( "*** SMS MESSAGE CONTENT ***" );
 //   Serial.println( msg );
 //   Serial.println( "*** END OF SMS MESSAGE ***" );
    ProcessSms( msg );
  }

  ClearGprsMsg();
  // EN: Always clear the flag
  SmsContentFlag = 0; 
}
************************************************

am Getting result in serial monitor : AT+CMGF=1
AT+CMGF=1

after sending sms also no change..

please help me

Original comment by jaa...@gmail.com on 16 Apr 2014 at 7:02

GoogleCodeExporter commented 8 years ago
GSM shield don't work on arduino mega, but working for arduino uno.
has any fix?

Original comment by vaja...@gmail.com on 10 May 2014 at 11:07

GoogleCodeExporter commented 8 years ago
hello...i am very new to arduino. i have a EFcom shield and arduino mega 2560. 
can someone help me to interface these two together. it ll be easier if you can 
show me it using images as im very new to arduino. i have read about this on 
the following link but still it s not clear how to do it. thank you very much.
http://www.instructables.com/id/Tutorial-EFCom-GRPSGSM-Shield-Arduino/?ALLSTEPS

Original comment by imeshuvi...@gmail.com on 16 Aug 2014 at 11:14

GoogleCodeExporter commented 8 years ago
Check this one out 
http://www.theengineeringprojects.com/2014/06/send-sms-with-arduino-uno-and-sim9
00d-using-at-commands.html

Original comment by theenggp...@gmail.com on 14 Feb 2015 at 10:56