use something like 

init-string = "AT+CNMI=2,3,0,1,0;+CMEE=1"

separate different commands with ;

see kannel doc for more info

in modem config


On Tue, 2009-01-06 at 14:54 -0800, Drew Stockler wrote:
> Sorry I am very new to this. How do I send that command  to the gsm
> modem?
> 
> Thanks,
> Drew
> 
> --- On Tue, 1/6/09, Alvaro Cornejo <[email protected]> wrote:
>         From: Alvaro Cornejo <[email protected]>
>         Subject: Re: AT2[/dev/ttyS0]: Generic error: ERROR
>         To: "Drew Stockler" <[email protected]>
>         Cc: [email protected]
>         Date: Tuesday, January 6, 2009, 4:07 PM
>         
>         use at*cmee=1 or 2 to get error verbose
>         
>         
>         
> |-----------------------------------------------------------------------------------------------------------------|
>         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
>         
>         
>         
>         On Tue, Jan 6, 2009 at 4:41 PM, Drew Stockler <[email protected]>
>         wrote:
>         > This mornig I was getting this error in the bearerbox log. It was 
> because
>         I
>         > had modemtype = wavecom. I changed it to auto and I was able to 
> send my
>         > first text messages. I then saved that config file and started 
> working a
>         > config file that would include dlr storage in mysql. That didnt go 
> to well
>         > so i reverted back to the config file that worked. However I 
> started to
>         get
>         > this error again.  It just repeats. Everything seems to connect 
> correctly
>         > until i send a message. the username and passwords are marked out 
> but they
>         > are correct in the config file and the
>          url.
>         >
>         >
>         
> http://localhost:13004/cgi-bin/sendsms?username=*****&password=****&to=4043078165&text=test
>         >
>         > DEBUG: boxc_receiver: sms received
>         > 2009-01-06 15:20:35 [7358] [13] DEBUG: send_msg: sending msg to box:
>         > <127.0.0.1>
>         > 2009-01-06 15:20:37 [7358] [6] DEBUG: AT2[/dev/ttyS0]: 
> TP-Validity-Period:
>         > 24.0 hours
>         > 2009-01-06 15:20:37 [7358] [6] DEBUG: AT2[/dev/ttyS0]: --> 
> AT+CMGS=17^M
>         > 2009-01-06 15:20:37 [7358] [6] DEBUG: AT2[/dev/ttyS0]: <-- >
>         > 2009-01-06 15:20:37 [7358] [6] DEBUG: AT2[/dev/ttyS0]: send command
>         status:
>         > 1
>         > 2009-01-06 15:20:37 [7358] [6] DEBUG: AT2[/dev/ttyS0]: -->
>         > 0011000A8104347018560000A704F4F29C0E
>         > 2009-01-06 15:20:37 [7358] [6] DEBUG: AT2[/dev/ttyS0]: --> ^Z
>         > 2009-01-06 15:20:39 [7358] [6] DEBUG: AT2[/dev/ttyS0]: <-- >
>         > 2009-01-06 15:20:39 [7358] [6] DEBUG: AT2[/dev/ttyS0]:
>          <-- ERROR
>         > 2009-01-06 15:20:39 [7358] [6] ERROR: AT2[/dev/ttyS0]: Generic 
> error:
>         ERROR
>         > 2009-01-06 15:20:39 [7358] [6] DEBUG: AT2[/dev/ttyS0]: send command
>         status:
>         > -1
>         > 2009-01-06 15:20:39 [7358] [6] DEBUG: AT2[/dev/ttyS0]: --> 
> AT+CMGS=17^M
>         > 2009-01-06 15:20:39 [7358] [6] DEBUG: AT2[/dev/ttyS0]: <-- >
>         > 2009-01-06 15:20:39 [7358] [6] DEBUG: AT2[/dev/ttyS0]: send command
>         status:
>         > 1
>         > 2009-01-06 15:20:39 [7358] [6] DEBUG: AT2[/dev/ttyS0]: -->
>         > 0011000A8104347018560000A704F4F29C0E
>         > 2009-01-06 15:20:40 [7358] [6] DEBUG: AT2[/dev/ttyS0]: --> ^Z
>         > 2009-01-06 15:20:42 [7358] [6] DEBUG: AT2[/dev/ttyS0]: <-- >
>         > 2009-01-06 15:20:42 [7358] [6] DEBUG: AT2[/dev/ttyS0]: <-- ERROR
>         > 2009-01-06 15:20:42 [7358] [6] ERROR: AT2[/dev/ttyS0]: Generic 
> error:
>         ERROR
>         > 2009-01-06 15:20:42 [7358] [6] DEBUG: AT2[/dev/ttyS0]: send
>          command
>         status:
>         > -1
>         >
>         > Here is the config file
>         >
>         > #
>         > # Sample configuration file for Kannel bearerbox on Debian.
>         > # See the documentation for explanations of fields.
>         > #
>         >
>         > # HTTP administration is disabled by default. Make sure you set the
>         > # password if you enable it.
>         >
>         > group = core
>         > admin-port = 13000
>         > admin-password = bar
>         > admin-deny-ip = "*.*.*.*"
>         > admin-allow-ip = ""
>         > smsbox-port = 13003
>         > wdp-interface-name = "*"
>         > log-file = "/var/log/kannel/bearerbox.txt"
>         > log-level = 0
>         > box-deny-ip = "*.*.*.*"
>         > box-allow-ip = "127.0.0.1"
>         >
>         >
>         >
>         > group = smsc
>         > smsc = at
>         > modemtype = auto
>         > device = /dev/ttyS0
>         > my-number = 13124010078
>         > sms-center =13123149810
>         > connect-allow-ip = 127.0.0.1
>         >
>         >
>         >
>         > group =
>          sms-service
>         > keyword =
>         > keyword-regex = .*
>         > catch-all = yes
>         > max-messages = 0
>         > get-url = "http://localhost/sms?phone=%p&text=%a";
>         >
>         > group = sendsms-user
>         > username = *******
>         > password = ****
>         > max-messages = 10
>         > concatenation = true
>         >
>         > group = smsbox
>         > bearerbox-host = 127.0.0.1
>         > sendsms-port = 13004
>         > global-sender = 3124010078
>         > log-file = "/var/log/kannel/smsbox.txt"
>         > log-level = 0
>         >
>         > include= "/usr/share/doc/kannel/examples/modems.conf"
>         >
>         >
>         >
>         >
> 


Reply via email to