A-GPS client implementation


#1

Hi,

I was working with an Q2686 and I want to implement something like an A-GPS client. I don’t need a exactly positioning, only near positioning.

There is no problem to implement it on Q2686 or in software PC. The Q2686 can send cells parameters to a remote server and this remote server make geolocation.

I know that I can cell info with “AT+CCED” command, but I don’t know how can I implement the A-GPS client in Q2686 nor remote server. I googled so much as I can, but I only get some A-GPS server address, but I don’t know how can I connect with them…

Can you help me?

Thanks in advance…


#2

What, exactly, does that mean?

You keep saying “GPS”, but it sounds like you don’t want to use GPS at all - is that right?

You just want something based on GSM cell location - yes?

I think it involves paying them some money - then they will grant you access to their services…


#3

Hi,

Thanks for your answer…

Yes, I want GSM cell location. With Q2686 and AT+CCED I can get cell information and power, then I’m trying to use google GeolocationAPI ( code.google.com/p/gears/wiki/GeolocationAPI ), but I’m not sure how can I use this, I’m trying some things, but I can obtain any response diferent of ERROR when trying to make the HTTP POST.

This is my sequence command:

AT+WIPCFG=1

OK

AT+WIPBR=1,6

OK

AT+WIPBR=2,6,11,“airtelnet.es”

OK

AT+WIPBR=2,6,0,“vodafone”

OK

AT+WIPBR=2,6,1,“vodafone”

OK

AT+WIPBR=4,6,0

OK
AT+WIPCREATE=5,1,“http://www.google.com/loc/json",80,"","

OK

+WIPREADY: 5, 1
AT+WIPOPT=5,1,1,51

+WIPOPT: 5,51,0

OK
AT+WIPOPT=5,1,2,53,6

OK
AT+WIPFILE,5,1,4,“http://www.google.com/loc/json

ERROR
AT+WIPFILE,5,1,4,“http://www.google.com/loc/json?{“version”:“1.1.0”,“host”:"maps.google.com”"

ERROR
AT+WIPFILE,5,1,4,"http://www.google.com/loc/json?{“version”:“1.1.0”,“host”:“maps.google.com”}"

ERROR
AT+WIPFILE,5,1,4,“http://www.google.com/loc/json?{version=1.1.0,host=maps.google.com

ERROR
AT+WIPFILE,5,1,4,“http://www.google.com/loc/json?{version=1.1.0,host=maps.google.com”}

ERROR
AT+WIPFILE,5,1,4,“http://www.google.com/loc/json?version=1.1.0,host=maps.google.com

ERROR

Do you have any idea???


#4

if you enable the error number, you might find out what is wrong with your request

AT+CMEE=1

#5

You really need to find out how to use it first!

Once you know how to use it, then you can start thinking about how ot implement that on a Q26 using WIPsoft.


#6

Hi!

This is the form I can obtain response:

Using a PC software I send this HTTP POST (I add one image of software):


POST: google.com/loc/json : HTTP/1.1

Headers:
Host: google.com
Content-Length:228

Request Body:
{“version”:“1.1.0”,“host”:“maps.google.com”,“cell_towers”:[{“age”:0,“signal_strength”:-87,“cell_id”:31781,“location_area_code”:39501,“mobile_country_code”:214,“mobile_network_code”:01}]}

And then, I get good response:

7f
{“location”:{“latitude”:39.460416,“longitude”:-0.401935,“accuracy”:621.0},“access_token”:“2:tyDY56DZ5Q9-IeYi:nv_ZyGyv_zLWU1zB”}
0

But when I try the same with Q26 I allways get an error (CME: 839) and I don’t know what is the problem…

Thanks in advance,


#7

Hi,

I advanced a little more, the error was because the url address had not the “http://” then, I can connect, but I get bad response:

AT+WIPFILE=5,1,4,“http://www.google.com/loc/json","","",“Host”,“www.google.com”,“Content-Length”,"186

CONNECT
/*******************************************here I send
{“version”:“1.1.0”,“host”:“maps.google.com”,“radio_type”:“gsm”,“request_address”:true,“cell_towers”:[{“age”:0,“signal_strength”:-87,“cell_id”:31781,“location_area_code”:39501,“mobile_country_code”:214,“mobile_network_code”:01}]}
/*****************************************then I get

Bad Request

Bad Request

Error 400

+WIPFILE: 5,1,4,400,“Bad Request”

OK