For me it seems a problem with your modem due to the modem itself or
with the network.

As posted in a previous mail:

AT+CMGS=XYZ                                          //Tells modem you
want to send message of XYZ octets (excluding the two initial zeros)
0011000B.... what ever the PDU is                // full message pdu
<ctrl-z>                                                       // end
of PDU => process the message.

ie the sequence is:

2010-04-28 12:53:00 [2611] [6] DEBUG: AT2[gw]: --> AT+CMGS=22^M
2010-04-28 12:53:00 [2611] [6] DEBUG: AT2[gw]: <-- >
2010-04-28 12:53:00 [2611] [6] DEBUG: AT2[gw]: send command status: 1
2010-04-28 12:53:00 [2611] [6] DEBUG: AT2[gw]: -->
0011000881627713150000A70BC8329BFD06DDDF723619
2010-04-28 12:53:00 [2611] [6] DEBUG: AT2[gw]: --> ^Z
2010-04-28 12:53:03 [2611] [6] DEBUG: AT2[gw]: <-- >


When kannel send the CMGS=22 to modem it tells it to be ready to
receive a message for transmition of 22octets in lenght. then waits
for the answer from modem to send the message (send command status: 1)
and then sends the PDU.

In your case, your modems tells kannel it is bussy and can not receive
the new message and retry later. (your error 515).

This could means several thinks that might be happen inside the modem,
and thus kannel can't do anything about it:

- The modem is re-initializing due to a problem in it. Check its
firmware and if available/posible, upgrade it.
- The modem is processing a previous message and can't receive another one
- There is a problem with the networks that is delaying the message
transmission.
- Network is bussy and the modem has its buffer full, so it can't
receive more messages

I'll test with another modem/gsm phone to see if there is a difference.

Also note that networks normally get klugged from time to time and it
is normal to have such error sporadically.

Hope helps

Alvaro



|-----------------------------------------------------------------------------------------------------------------|
Envíe y Reciba Datos y mensajes de Texto (SMS) hacia y desde cualquier
celular y Nextel
en el Perú, México y en mas de 180 paises. Use aplicaciones 2 vias via
SMS y GPRS online
              Visitenos en www.perusms.NET www.smsglobal.com.mx y
www.pravcom.com



2010/5/4 Nikos Balkanas <[email protected]>:
> Hi,
>
> I should wait for more experienced modem people, but I 'll give it a shot.
>
> 1) Please read latest User's guide about modem initialization and how to
> work +CMEE in your init string.
> 2) Googling for CMGS, I see that this should be the destination number
> string, i.e. "+8259123456", 129. The second part (129) is optional and
> indicates whether it is international or local numbering plan.
> Destination should be in double quotes. Now, 52 doesn't seem to me that  it
> is a valid number.
>
> It would seem improbable such a feature in kannel not to work correctly, but
> out of curiosity, is it the same the times that it works?
>
> BR,
> Nikos
>
> ----- Original Message -----
> From: Harish Tella
> To: [email protected]
> Sent: Tuesday, May 04, 2010 7:28 AM
> Subject: $50 reward for solution to +CME ERROR: 515 when sending sms on gsm
> modem
> Hello, I will paypal $50 USD to whoever can help me solve this error. If
> multiple people offer a partial solution that works I will split the reward
> up equally. I'm in a hurry to solve this and greatly appreciate any help.
>
> Kannel Version: 1.4.3
> OS: Ubuntu Karmic Koala (9.10) , Linux 2.6.31-20
> Processor: Intel Pent. 4, hyperthreading
> Libxml version: unsure how to find this
> I got libxml2, version:  2.7.5.dfsg-1ubuntu1.1
>
> Modem:
> Multi-Tech MultiModem MTCBA-G-F2 (Serial Connection)
> manual:
> http://www.multitech.com/en_US/DOCUMENTS/Collateral/manuals/S000304M.pdf
> AT commands:
> http://www.multitech.com/en_US/DOCUMENTS/Collateral/manuals/S000293J.pdf
>
> Carrier:
> AT&T pay as you go SIM, in the U.S.A.
>
> My config files:
> kannel.conf:
> http://dl.dropbox.com/u/426534/kannel.conf.txt
> modems.conf:
> http://dl.dropbox.com/u/426534/modems.conf.txt
>
> Text from smsc.log that contains the error:
> http://dl.dropbox.com/u/426534/kannel_error.txt
>
> My problem: sometimes my modem fails to send an outgoing message with the
> following error.
>
> :--> AT+CMGS=52^M
> : <--
> : <-- +CME ERROR: 515
> : Generic error: +CME ERROR: 515
> : send command status: -1
>
> my modem's manual says CME ERROR: 515 means: Please wait, init or command
> processing in progress.
>
> The first half of the log linked above is the sequence of things when a
> message gets received by the modem and the reply doesn't get sent properly.
> The second half is the sequence when the reply goes out properly.
>
> This problem happens randomly. Sometimes I can cause it happen by sending a
> lot of texts to the modem in a short burst.
>
> I am not sending the reply sms by returning it in the response when
> sms-service calls my server's url. I just have the server return an empty
> page. Instead I have the server calling kannel's sendsms url to send the
> reply sms. I'm doing it this way because it was the only way I could put
> newlines in the sms response. I'm not sure if this makes a difference here.
>
> I thought the error was being caused because the AT+CMGS=52^M command was
> sent too soon which is what was causing the error. So I set "need-sleep =
> true" and "sendline-sleep = 200" but it didn't help.
>
> Not sure what direction to go from here. Any help is really appreciated.
>
> Harish Tella
>
>
>
>
>

Reply via email to