Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronic Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

Register Log in

BenQ M22 and M23 GPRS module problem

Status
Not open for further replies.

techie

Advanced Member level 3
Joined
Feb 5, 2002
Messages
839
Helped
58
Reputation
116
Reaction score
9
Trophy points
1,298
Location
Pakistan
Activity points
7,799
benq m22

I am using BenQ M23 module (looks same as M22). The following is the terminal log. Can someone let me know what is the problem.

AT

OK
AT+CGDCONT=1,"IP","INTERNET"

OK
AT%CGPCO=1,"PAP,user,pass",1 (actual user and pass used)

OK
AT$DESTINFO="72.14.203.104",1,80

$DESTINFO: "72.14.203.104", 1, 80

OK
ATD*97#

Wait Socket Open
<0><0>
OK
<0>

Then nothing happens. Cannot downlaod HTTP file.
I can disconnect by +++(delay)ATH.
 

artem

Advanced Member level 4
Joined
May 22, 2003
Messages
1,350
Helped
126
Reputation
252
Reaction score
32
Trophy points
1,328
Location
Turkey
Activity points
13,461

    techie

    points: 2
    Helpful Answer Positive Rating

techie

Advanced Member level 3
Joined
Feb 5, 2002
Messages
839
Helped
58
Reputation
116
Reaction score
9
Trophy points
1,298
Location
Pakistan
Activity points
7,799
m23 benq

I have read both the articles. I also did manage to communicate with a slef-made server (using winsock.dll in VB6) on another real IP and the data sending/receiveing over TCP socket is working OK. THe problem is that I cannot download an HTTP file from a standard web-server.

My question now is this. What is the difference between a TCP server listening on a port and a standard web-server listening on port 80. The socket connection in both cases is established OK by the M22. But in case of a web-server, there is no response when I send the standard HTTP GET command set composing of a few lines and carraige returns.
 

artem

Advanced Member level 4
Joined
May 22, 2003
Messages
1,350
Helped
126
Reputation
252
Reaction score
32
Trophy points
1,328
Location
Turkey
Activity points
13,461
how to send data to web server from gprs module

What you mean by tcp server ? Which port to use is not an issue i think. If server uses different than 80 port it means you should establish connection to that port . In software the server asks tcp to forward packets when port is its own .

From rfc for http format of request is set as :
Code:
       Full-Request   = Request-Line             ; Section 5.1
                        *( General-Header        ; Section 4.3
                         | Request-Header        ; Section 5.2
                         | Entity-Header )       ; Section 7.1
                        CRLF
that means it is concluded with CR and LF both . Do use just CR ?

DO you have an example captured data for request from browser and did you trace arrived packet from your mobile to the server if so did you match the request made from browser to one you send from modem?

Added after 2 minutes:

you can use etherial to capture packets on your server PC .
 

techie

Advanced Member level 3
Joined
Feb 5, 2002
Messages
839
Helped
58
Reputation
116
Reaction score
9
Trophy points
1,298
Location
Pakistan
Activity points
7,799
benq m22

That is a good idea artem. I shall try using a CR+LF. You are right that I was using CR only. Maybe that is the problem. I will try tomorrow morning and let you know. Thanks again.
 

artem

Advanced Member level 4
Joined
May 22, 2003
Messages
1,350
Helped
126
Reputation
252
Reaction score
32
Trophy points
1,328
Location
Turkey
Activity points
13,461
benq m22 ejemplo

If problem will persist, please include packet capture made on server side made from modem and another PC's browser .

That will make our efforts much easier , i think .
http://www.ethereal.com/

It will take just half of hour to get started but you will enjoy it .
 

    techie

    points: 2
    Helpful Answer Positive Rating

techie

Advanced Member level 3
Joined
Feb 5, 2002
Messages
839
Helped
58
Reputation
116
Reaction score
9
Trophy points
1,298
Location
Pakistan
Activity points
7,799
how i send data to server through gprs module

I have used ethereal before. It is an excellent tool for this purpose. The problem is that I dont have access to the server since it resides with the ISP. But I am sure your idea of CRLF would work. I am pretty sure that was the problem.
 

cdbarrera

Newbie level 4
Joined
Mar 10, 2009
Messages
5
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,281
Activity points
1,314
benq gsm/gprs module

hi everyone. :) I'm trying to establish a connection in a server and send data via TCP connection using BenQ GSM/GPRS module

I'm using the following series of commands:

AT+CGDCONT=1,"IP", "smart1"
AT$DESTINFO="122.52.17.122",1,1300
AT$NOSLEEP=1
ATD*97#

After the dial command, the hyperterminal shows this:

Wait Socket Open

ERROR

OK

CONNECT

OK

OK

NO CARRIER


What does that mean? What is the problem with the connection? Should I use ATD*99# because I'm dialing from the Philippines? Thanks! :)
 

techie

Advanced Member level 3
Joined
Feb 5, 2002
Messages
839
Helped
58
Reputation
116
Reaction score
9
Trophy points
1,298
Location
Pakistan
Activity points
7,799
benq gsm gprs module

You are missing the command

AT%CGPCO=1,"PAP","user,password.....

check the exact command since I maybe making a syntax mistake
 

cdbarrera

Newbie level 4
Joined
Mar 10, 2009
Messages
5
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,281
Activity points
1,314
gprs at commands for benq

techie said:
You are missing the command

AT%CGPCO=1,"PAP","user,password.....

check the exact command since I maybe making a syntax mistake
Someone told me that the command at%cgpco can already be omitted. Is that correct? What does that at command do?

I also tried connecting using atd*99# and the output is this:

~ÿ}#À!}!}#} }3}"}&} } } } }#}%Â#}%}'}"}(}"ˆé~~ÿ}#À!}!}#} }3}"}&} } } } }#}%Â#}%}
'}"}(}"ˆé~~ÿ}#À!}!}#} }3}"}&} } } } }#}%Â#}%}'}"}(}"ˆé~~ÿ}#À!}!}#} }3}"}&} } } }
}#}%Â#}%}'}"}(}"ˆé~~ÿ}#À!}!}#} }3}"}&} } } } }#}%Â#}%}'}"}(}"ˆé~~ÿ}#À!}!}#} }3}
"}&} } } } }#}%Â#}%}'}"}(}"ˆé~~ÿ}#À!}!}#} }3}"}&} } } } }#}%Â#}%}'}"}(}"ˆé~~ÿ}#À
!}!}#} }3}"}&} } } } }#}%Â#}%}'}"}(}"ˆé~~ÿ}#À!}!}#} }3}"}&} } } } }#}%Â#}%}'}"}(
}"ˆé~~ÿ
NO CARRIER

I've researched somewhere and they said that these are LCP packets. Do you know why I got disconnected?
Thanks! :)
 

techie

Advanced Member level 3
Joined
Feb 5, 2002
Messages
839
Helped
58
Reputation
116
Reaction score
9
Trophy points
1,298
Location
Pakistan
Activity points
7,799
benq m23 gprs

The *99# command does not use the TCP/IP stack on the modem. It is used to implement the PPP + TCP/IP in your microcontroller.

Try using the CGPCO command and see what happens.
 

cdbarrera

Newbie level 4
Joined
Mar 10, 2009
Messages
5
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,281
Activity points
1,314
benq m 23 a

I already tried the %cgpco command, the output is still

Wait Socket Open

ERROR

OK

CONNECT

OK

OK

NO CARRIER


what could possibly go wrong with my conncection? On the server side, I used Python Socket programming .
 

techie

Advanced Member level 3
Joined
Feb 5, 2002
Messages
839
Helped
58
Reputation
116
Reaction score
9
Trophy points
1,298
Location
Pakistan
Activity points
7,799
at%cgpco=1 benq

Try to connect to a working server, preferrably a web server that is up and running. Connect to this using standard port 80. Sometimes some service providers block all ports on GPRS except 9201, 8080 and the standard HTTP, FTP, POP3, SMTP etc. Since you are using port 1300, that may be blocked.
 

Status
Not open for further replies.
Toggle Sidebar

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Top