problem with sim card

Hi
I can use another sim card from a Portuguese network (TMN) to send and receive sms and internet?
I use arduino uno r3 and the last Arduino GSM Shield

Hi Joaoj,
yes, the GSM shield works with any sim card enabled to send and receive sms or internet. Let us know if you need other support.

Best regards,
Alberto

Thanks.

when I load the example "testemodem" shows me this:
Starting modem test...modem.begin() succeeded
Checking IMEI...Modem's IMEI:
359231038082408
Resetting modem...Modem is functoning properly

when I load the example "gsmscannetworks" or other shows me this:
"GSM networks scanner"
and do not go to the next step

when I load the example "pinmanagement" shows me this:
Change PIN example

PIN & PUK locked. Use PIN2/PUK2 in a mobile phone.

Note: the simcard has no pin code and works well on a mobile phone...

Hello, may you execute the TestGPRS example, changing the line
GSM gsmAccess();
for
GSM gsmAccess(true);

Execute the tool with the Monitor Serial open, and copy here the dumped codes. So we can see if there is any connectivity issue.

Thanks.

Hi :slight_smile:
this is the dumping:

Connecting GSM network...AT%13%
0 9>AT%13%%13%%10%OK%13%%10%
AT+CGREG?%13%
9 40>AT+CGREG?%13%%13%%10%+CGREG: 0,2%13%%10%%13%%10%OK%13%%10%
AT+CGREG?%13%
40 71>AT+CGREG?%13%%13%%10%+CGREG: 0,2%13%%10%%13%%10%OK%13%%10%
AT+CGREG?%13%
85 116>AT+CGREG?%13%%13%%10%+CGREG: 0,2%13%%10%%13%%10%OK%13%%10%
AT+CGREG?%13%
116 19>AT+CGREG?%13%%13%%10%+CGREG: 0,1%13%%10%%13%%10%OK%13%%10%
AT+IFC=1,1%13%
19 36>AT+IFC=1,1%13%%13%%10%OK%13%%10%
AT+CMGF=1%13%
36 52>AT+CMGF=1%13%%13%%10%OK%13%%10%
AT+CLIP=1%13%
52 68>AT+CLIP=1%13%%13%%10%OK%13%%10%
ATE0%13%
68 79>ATE0%13%%13%%10%OK%13%%10%
AT+COLP=1%13%
79 85>%13%%10%OK%13%%10%
OK
Enter your APN: internet
Now, enter your login: tmn
Finally, enter your password: Attaching to GPRS with your APN...
AT+CGATT=1%13%
85 91>%13%%10%OK%13%%10%
AT+QIFGCNT=0%13%
91 97>%13%%10%OK%13%%10%
AT+QICSGP=1,"internet","tmn","tmnnet"%13%
97 103>%13%%10%OK%13%%10%
AT+QIMUX=0%13%
103 109>%13%%10%OK%13%%10%
AT+QIMODE=1%13%
109 115>%13%%10%OK%13%%10%
AT+QINDI=1%13%
115 121>%13%%10%OK%13%%10%
AT+QIREGAPP%13%
121 127>%13%%10%OK%13%%10%
AT+QIACT%13%
127 5>%13%%10%OK%13%%10%
OK
If your carrier uses a proxy, enter it, if not press enter:

Good news are, your shield is connecting OK to the network and you can procceed with the examples.

Only bad thing is that gsmscannetworks is not running properly in your environment... Following your post, it looks like gsmAccess.begin() is not giving an answer in gsmscannetworks. The funny thing is that gsmAccess.begin() runs OK in TestGPRS.

I've found something that can be improved in the network scanning code but your sketch doesn't even reach that point...

I'll ask you a couple of things:

  • Have you left gsmscannetworks running for at least a couple of minutes?
  • May you copy a dump of gsmscannetworks?

Have you tried any example?

Hi :slight_smile:
incredible! Now everything works and no longer need to put the "true" code in "GSM gsmAccess()"

gsmscannetworks dump:

GSM networks scanner
Modem IMEI: 359231038082408
Scanning available networks. May take some seconds.

TMN
OPTIMUS

Current carrier: TMN
Signal Strength: 16 [0-31]
Scanning available networks. May take some seconds.

TMN


thanks
:slight_smile: :slight_smile: :slight_smile:

Hijacking this thread, guess it's ok.

Put a swisscom sim with pin into my gsm shield.
Changed the TestGPRS example and changed the code to GSM gsmAccess(true).

Dump is

Connecting GSM network...AT%13%
0 9>AT%13%%13%%10%OK%13%%10%
AT+CPIN=7779%13%
9 44>AT+CPIN=7779%13%%13%%10%+CPIN: READY%13%%10%%13%%10%OK%13%%10%
AT+CGREG?%13%
44 75>AT+CGREG?%13%%13%%10%+CGREG: 0,2%13%%10%%13%%10%OK%13%%10%
AT+CGREG?%13%
75 106>AT+CGREG?%13%%13%%10%+CGREG: 0,2%13%%10%%13%%10%OK%13%%10%
AT+CGREG?%13%
106 23>AT+CGREG?%13%%13%%10%+CGREG: 0,2%13%%10%%13%%10%OK%13%%10%%13%%10%Call Ready%13%%10%
AT+CGREG?%13%
23 54>AT+CGREG?%13%%13%%10%+CGREG: 0,1%13%%10%%13%%10%OK%13%%10%
AT+IFC=1,1%13%
54 71>AT+IFC=1,1%13%%13%%10%OK%13%%10%
AT+CMGF=1%13%
71 87>AT+CMGF=1%13%%13%%10%OK%13%%10%
AT+CLIP=1%13%
87 103>AT+CLIP=1%13%%13%%10%OK%13%%10%
ATE0%13%
103 114>ATE0%13%%13%%10%OK%13%%10%
AT+COLP=1%13%
114 120>%13%%10%OK%13%%10%
OK

it then asks me for the apn and I enter gprs.swisscom.ch (found on http://forums.pinstack.com/f24/tcp_apn_wap_gateway_port_carrier_settings-360/ via http://arduino.cc/en/Guide/ArduinoGSMShield)

But then it stays on

Enter your APN:

for ever...

looks like it's a problem with the serial interface.

because this code works with my swisscom settings:

// include the GSM library
#include <GSM.h>

// PIN number if necessary
#define PINNUMBER "7779"

// APN information obrained from your network provider
#define GPRS_APN       "gprs.swisscom.ch" // replace with your GPRS APN
#define GPRS_LOGIN     ""                  // replace with your GPRS login
#define GPRS_PASSWORD  "gprs"             // replace with your GPRS password

// initialize the library instances
GSMClient client;
GPRS gprs;
GSM gsmAccess;

// This example downloads the URL "http://arduino.cc/latest.txt"

char server[] = "arduino.cc"; // the base URL
char path[] = "/latest.txt"; // the path
int port = 80; // the port, 80 for HTTP

void setup()
{
  // initialize serial communications
  Serial.begin(9600);
  Serial.println("Starting Arduino web client.");
  // connection state
  boolean notConnected = true;

  // Start GSM shield
  // pass the PIN of your SIM as a parameter of gsmAccess.begin()
  while(notConnected)
  {
    if((gsmAccess.begin(PINNUMBER)==GSM_READY) &
        (gprs.attachGPRS(GPRS_APN, GPRS_LOGIN, GPRS_PASSWORD)==GPRS_READY))
      notConnected = false;
    else
    {
      Serial.println("Not connected");
      delay(1000);
    }
  }

  Serial.println("connecting...");

  // if you get a connection, report back via serial:
  if (client.connect(server, port))
  {
    Serial.println("connected");
    // Make a HTTP request:
    client.print("GET ");
    client.print(path);
    client.println(" HTTP/1.0");
    client.println();
  } 
  else
  {
    // if you didn't get a connection to the server:
    Serial.println("connection failed");
  }
}

void loop()
{
  // if there are incoming bytes available 
  // from the server, read them and print them:
  if (client.available())
  {
    char c = client.read();
    Serial.print(c);
  }

  // if the server's disconnected, stop the client:
  if (!client.available() && !client.connected())
  {
    Serial.println();
    Serial.println("disconnecting.");
    client.stop();

    // do nothing forevermore:
    for(;;)
      ;
  }
}

Have you configured the Serial Monitor to add both NL&CR?

Thanks.

@Joaoj , you wrote:

Hi
incredible! Now everything works and no longer need to put the "true" code in "GSM gsmAccess()"

But I don't understand, vhat you've done? I have the same symptoms as you had, what to do?

Hi
when I changed the line:

GSM gsmAccess();
for
GSM gsmAccess(true);

in serial monitor asked for this information:

Enter your APN: internet
Now, enter your login: tmn
Finally, enter your password:

after entering data work perfectly for ever... :slight_smile:

Hi everyone,

I have recieved my Arduino GSM shield 2 days back and trying to connect my shield to Internet using Vodafone SIM(India).

I have followed the steps mentioned above. I am getting following stack trace when PIN is 1234

Connecting GSM network...AT%13%
0 9>AT%13%%13%%10%OK%13%%10%
AT+CPIN=1234%13%
9 44>AT+CPIN=1234%13%%13%%10%+CPIN: READY%13%%10%%13%%10%OK%13%%10%
AT+CGREG?%13%
44 75>AT+CGREG?%13%%13%%10%+CGREG: 0,2%13%%10%%13%%10%OK%13%%10%
AT+CGREG?%13%
75 74>%255%%5%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%
AT+CGREG?%13%

and getting this when there is no PIN

Connecting GSM network...AT%13%
0 127>%255%%1%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%%0%
ERROR

Need your support and guidance to resolve the problem. I am stuck.

Problem I mentioned above is Solved.

A correct power supply is mandatory for boards/shields. I was using USB port for power supply which was 5V appx. After plugging it to 12V/1A power supply (on UNO + GSM shield), I am now able to connect to internet and send SMS. It has nothing w.r.t SIM card used

hi guys am new to arduino, i got the arduino uno r3 and the gsm shield sim900 i placed the shield on the arduino and connected the arduino to my computer but when i do the test modem it says

error, modem is not answering
what the problem could be need help please

hi i used this code
#include "SIM900.h"
#include <SoftwareSerial.h>
//If not used, is better to exclude the HTTP library,
//for RAM saving.
//If your sketch reboots itself proprably you have finished,
//your memory available.
//#include "inetGSM.h"

//If you want to use the Arduino functions to manage SMS, uncomment the lines below.
#include "sms.h"
SMSGSM sms;

//To change pins for Software Serial, use the two lines in GSM.cpp.

//GSM Shield for Arduino
//www.open-electronics.org
//this code is based on the example of Arduino Labs.

//Simple sketch to send and receive SMS.

int numdata;
boolean started=false;
char smsbuffer[160];
char n[20];

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

if(started){
//Enable this two lines if you want to send an SMS.
//if (sms.SendSMS("3471234567", "Arduino SMS"))
//Serial.println("\nSMS sent OK");
}

};

void loop()
{
if(started){
//Read if there are messages on SIM card and print them.
if(gsm.readSMS(smsbuffer, 160, n, 20))
{
Serial.println(n);
Serial.println(smsbuffer);
}
delay(1000);
}
};
the gsm work and recive sms but nothing appears in the serial monitar.any help please?

Hi, I have some problems too, with different SIM cards from Italian networks.
I tried to use, for two times, a new SIM from WIND company, see the attached picture, and the shield did not work ("not connected"). Furthermore the SIM, after these tests, did not work any more (on my cell phone I read: SIM refused).
Then I tried two different SIM, from TIM company and an old one from WIND, that work quite well.
I suspect that the new micro-SIM from WIND does not match well in the Shield, although the plastic shape is the same.

Paolo

it's only power supply problem...give it 12V DC and everything will work just fine!!!
The only problem is when u buy that damn thing noone tells u that...
just give 12v to yr arduino...

Hi Guys,

I am trying to use EE sim with the Arduino GSM shield, the sim if I use in my phone as has complete network coverage. But when trying to use with Arduino, I keep getting the CGREG message. Screen Dump included below, any suggestion how to resolve this would be helpful.
Note: I have used the telefonica sim as well, and that works some times.But I need to use the EE sim card.

Test Rig - Messages Sender starting
AT%13%
0 9>AT%13%%13%%10%OK%13%%10%
AT+CPIN=1111%13%
9 44>AT+CPIN=1111%13%%13%%10%+CPIN: READY%13%%10%%13%%10%OK%13%%10%
AT+CGREG?%13%
58 89>AT+CGREG?%13%%13%%10%+CGREG: 0,2%13%%10%%13%%10%OK%13%%10%
AT+CGREG?%13%
89 120>AT+CGREG?%13%%13%%10%+CGREG: 0,2%13%%10%%13%%10%OK%13%%10%
AT+CGREG?%13%
120 23>AT+CGREG?%13%%13%%10%+CGREG: 0,2%13%%10%%13%%10%OK%13%%10%
AT+CGREG?%13%
23 54>AT+CGREG?%13%%13%%10%+CGREG: 0,2%13%%10%%13%%10%OK%13%%10%
AT+CGREG?%13%
54 85>AT+CGREG?%13%%13%%10%+CGREG: 0,2%13%%10%%13%%10%OK%13%%10%
AT+CGREG?%13%
85 116>AT+CGREG?%13%%13%%10%+CGREG: 0,3%13%%10%%13%%10%OK%13%%10%
AT+CGREG?%13%
116 19>AT+CGREG?%13%%13%%10%+CGREG: 0,3%13%%10%%13%%10%OK%13%%10%
AT+CGREG?%13%
19 50>AT+CGREG?%13%%13%%10%+CGREG: 0,3%13%%10%%13%%10%OK%13%%10%
AT+CGREG?%13%
50 81>AT+CGREG?%13%%13%%10%+CGREG: 0,3%13%%10%%13%%10%OK%13%%10%
AT+CGREG?%13%
81 112>AT+CGREG?%13%%13%%10%+CGREG: 0,3%13%%10%%13%%10%OK%13%%10%
AT+CGREG?%13%
112 15>AT+CGREG?%13%%13%%10%+CGREG: 0,3%13%%10%%13%%10%OK%13%%10%
AT+CGREG?%13%
15 46>AT+CGREG?%13%%13%%10%+CGREG: 0,3%13%%10%%13%%10%OK%13%%10%
AT+CGREG?%13%
46 77>AT+CGREG?%13%%13%%10%+CGREG: 0,3%13%%10%%13%%10%OK%13%%10%
AT+CGREG?%13%
77 108>AT+CGREG?%13%%13%%10%+CGREG: 0,3%13%%10%%13%%10%OK%13%%10%
AT+CGREG?%13%
108 11>AT+CGREG?%13%%13%%10%+CGREG: 0,3%13%%10%%13%%10%OK%13%%10%
AT+CGREG?%13%
11 42>AT+CGREG?%13%%13%%10%+CGREG: 0,3%13%%10%%13%%10%OK%13%%10%
AT+CGREG?%13%
42 73>AT+CGREG?%13%%13%%10%+CGREG: 0,3%13%%10%%13%%10%OK%13%%10%

hello
Am facing the same issue that u had faced before with the send sms and test modem . Could u tell me how did u fix it nd infact when i do test modem, its showing me the IMEI as 0 and

Starting modem test...ERROR, no modem answer.
Checking IMEI...Modem's IMEI: 0
Resetting modem...Modem is functoning properly

hello all......am working on gsm shiled to sent sms.

when I load the example "testemodem" shows me this:

Starting modem test...ERROR, no modem answer.
Checking IMEI...Modem's IMEI: 0
Resetting modem...Modem is functoning properly

when I load the example "gsmscannetworks" or other shows me this:
"GSM networks scanner"
and do not go to the next step

when I load the example "pinmanagement" shows me this:
Change PIN example

PIN & PUK locked. Use PIN2/PUK2 in a mobile phone.