|
-
Jul 29th, 2009, 04:11 AM
#1
Thread Starter
Hyperactive Member
read GSM modem message
HI, how can i read out the message from the GSM modem. The follow code only manage to show "at+cmgl=all" which is not the mesage i want. anyone know how to solve it ?
vb.net Code:
[CODE]
With serialport
.PortName = "COM6"
.BaudRate = "115200"
.StopBits = IO.Ports.StopBits.One
.DataBits = 8
.Parity = IO.Ports.Parity.None
.ReadBufferSize = 10000
.ReadTimeout = 1000
.WriteBufferSize = 10000
.WriteTimeout = 10000
.RtsEnable = True
.Open()
.DiscardOutBuffer()
'for reading sms
atcCommand = "AT+CMGL=all" 'to read from inbox
.Write(atcCommand + vbCrLf) 'execute command on buffer
'code manage to get out what it wrote in the atcCommand
TextBox1.Text = .ReadExisting
End With
[/CODE]
-
Jul 29th, 2009, 07:09 AM
#2
Frenzied Member
Re: read GSM modem message
Hi,
there should be an 'incoming' event on the serial port that should list what comes back.
I know when I did this, I used the serial control from www.franson.com - although I know Dick Grier has some examples on his site
-
Jul 29th, 2009, 09:24 AM
#3
Thread Starter
Hyperactive Member
Re: read GSM modem message
well.. i look through it. but there is no key word for incoming event.. is it possible send me a working copy..?? thanks
-
Jul 30th, 2009, 01:20 AM
#4
Frenzied Member
Re: read GSM modem message
Hi,
take a look at the excellent article here - that should put you on the right lines.
-
Aug 3rd, 2009, 01:43 AM
#5
Thread Starter
Hyperactive Member
Re: read GSM modem message
My GSM modem don't have auto trigger function. it will not auto detect incoming data/msg.
How can i make my GSM modem auto detect incoming msg/data.
at+cnmi?
2,1,0,0
ok
but when i send a msg to my modem. it is not responing.. how am i going to make it auto detect ?
Last edited by Waka; Aug 3rd, 2009 at 01:51 AM.
-
Aug 3rd, 2009, 05:32 AM
#6
Frenzied Member
Re: read GSM modem message
how do you know it isn't responding and it isn't your code.
Try downloading an evaluation of the terminal emulator from http://www.cam.com/vxhpc.html and trying your commands on that
-
Aug 3rd, 2009, 09:03 AM
#7
Thread Starter
Hyperactive Member
Re: read GSM modem message
coz i using the same code to phone is workable.. when i use the at+cnmi? command
it will auto trigger to read message from inbox.. my phone show a respone when it receive new message.. but my gsm modem is not responing..
-
Sep 30th, 2009, 12:18 AM
#8
Junior Member
Re: read GSM modem message
Is it the same??
At+cmgl=all
or should it to be
at+cmgl="all"
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|