electronics forum

Rules | Recent posts | topic RSS | Search | Register  | Log in

SIM340Z GPRS Problem


Post new topic  Reply to topic    EDAboard.com Forum Index -> Professional Hardware and Electronics Design -> SIM340Z GPRS Problem
Author Message
Derek_Fairbairn



Joined: 02 Sep 2009
Posts: 3
Location: Perth Australia


Post02 Sep 2009 5:27   

sim340z send data


Hi,

I've been having a problem with the SimCom modem taking a long time to complete the AT+CIICR command.

This only appears to happen when the GSM signal level is marginal. (The AT+CSQ value is around 10). If the signal goes higher then it succeeds and if the signal goes lower it fails. However at this level it appears to take forever to complete.


These are the commands that were sent:

>AT+CSQ

+CSQ: 10,2

OK

>AT+CIPSTATUS
STATE: IP CLOSE

OK

>AT+CIPSHUT

SHUT OK

>AT+CIPSTATUS

OK

STATE: IP INITIAL

>AT+CIPSPRT=1

OK

>AT+CDNSORIP=0

OK

>AT+CIPSRIP=1

OK

>AT+CIPHEAD=1

OK

>AT+CGDCONT=1,"IP","internet"

OK

>AT+CSTT="internet","",""]

OK

>AT+CDNSCFG="208.67.222.222",""

OK

>AT+CIICR
+PDP: DEACT

+PDP: DEACT

+CREG: 0

+CGREG: 0

+CREG: 2

+CREG: 1

+CGREG: 1

+CREG: 0

+CGREG: 0

+CREG: 2

+CREG: 1

+CGREG: 1

+CREG: 0

+CGREG: 0

+CREG: 2

+CREG: 0

+CREG: 2

+CREG: 0

+CREG: 2

+CREG: 0

+CREG: 2

+CREG: 0

After 10 minutes there is still no OK or ERROR response for the AT+CIICR so my application times out.

I don't know how to deal with this situation. If it returns an ERROR then I could attempt a new connection. However it doesn't return anything apart from the +CREG and +CGREG URC events. I'm not sure if I should continue sending more AT commands when the AT+CIICR command hasn't finished.
Is there some way to interrupt the AT+CIICR command and start again?

Is there anything wrong with the commands that I am using?
Or is this a SIM340 or hardware fault?

99% of the time I can send/receive GPRS data normally, its just every now and again this happens.
Back to top
GSM Man



Joined: 15 Apr 2009
Posts: 357
Helped: 46
Location: New Jersey, USA


Post02 Sep 2009 13:40   

sim340 startup problem


As you've discovered, GPRS communications requires that you have a good signal level. I've seen it take a couple of minutes for the CIICR to return a status, but 10 minutes seems excessive. You can't abort the command once it's started. The best you can do is turn off the module and restart.
Back to top
movie_freak



Joined: 20 Mar 2007
Posts: 81
Helped: 2


Post11 Sep 2009 7:00   

at+ciicr


Hi,

CREG: 2 means that the module is searching for the network
CREG:0 its not registered with the network and also it's not searching
CREG:1 means that the module is registered with the operator network


One thing u could always do is check AT+CREG? before sending the AT+CIICR and if CREG: 1 then only fire the AT+CIICR command

Also, when ur modem is hangged with AT+CIICR, u can fire AT+CIPSHUT to interrupt it and to close the gprs context and bring back the modem to normal working condition. I've checked it , it works on my side.. i hope u can check it and it works to u as well..


Surya
Back to top
Derek_Fairbairn



Joined: 02 Sep 2009
Posts: 3
Location: Perth Australia


Post11 Sep 2009 7:25   

sim340z send data ip


Thanks for your responses.

I've modified the way my application works so that it will check that CREG: 1 before it attempts to send any data. This stops it attempting AT+CIICR when the GSM isn't good enough, and prevents it from locking up.

Also if it takes longer than 1 minute to respond I reboot the modem using the power key. I figured it was safer to reboot the GSM to get it back to a known state, instead of trying to interrupt it using AT commands.

As a side note, I found a fault in some of my hardware that was either causing this problem or making it worse.
I have one batch of hardware that can send GPRS at low signal levels - when RSSI is 4 or 5 - and another batch that must be over 12 to send.
It was the batch that needs a signal level over 12 that was having this problem.

I'm not sure exactly what the hardware problem is. The manufacturer is looking into it.
Back to top
Google
AdSense
Google Adsense




Post11 Sep 2009 7:25   

Ads




Back to top
GSM Man



Joined: 15 Apr 2009
Posts: 357
Helped: 46
Location: New Jersey, USA


Post11 Sep 2009 13:01   

simcom at+cgreg


Derek_Fairbairn wrote:
Also if it takes longer than 1 minute to respond I reboot the modem using the power key. I figured it was safer to reboot the GSM to get it back to a known state, instead of trying to interrupt it using AT commands.
You may experience problems doing it this way. When you shut down the module using the 'PWRKEY', it doesn't disconnect from the network as it does when you use the AT commands. So when you reconnect, the network thinks you are still connected and you may be denied a connection. I've seen this on a few occasions with devices that have experienced a power failure.
Back to top
Arabic versionBulgarian versionCatalan versionCzech versionDanish versionGerman versionGreek versionEnglish versionSpanish versionFinnish versionFrench versionHindi versionCroatian versionIndonesian versionItalian versionHebrew versionJapanese versionKorean versionLithuanian versionLatvian versionDutch versionNorwegian versionPolish versionPortuguese versionRomanian versionRussian versionSlovak versionSlovenian versionSerbian versionSwedish versionTagalog versionUkrainian versionVietnamese versionChinese version
Post new topic  Reply to topic    EDAboard.com Forum Index -> Professional Hardware and Electronics Design -> SIM340Z GPRS Problem
Page 1 of 1 All times are GMT + 1 Hour
Similar topics:
SIM300 or sim340Z (9)
Module Specification - information about the SIM340Z (1)
Gprs Problem In iran (6)
GPRS disconnection problem (6)
AT+CIPSEND SIM300C GPRS PROBLEM.. (1)
GSM/GPRS modem hang problem (13)
Problem with simcon GPRS Module (1)
Simcom Sim300 GPRS connection problem (12)
Simcom Sim300 GPRS connection problem (14)
microcontroller and gprs module interface problem (10)


Abuse || Administrator || Moderators || Support us || sitemap
topic RSS