Unable to get location on Windows Mobile inspite of having GPS

8 views
Skip to first unread message

ind.techie

unread,
Aug 28, 2008, 9:40:56 AM8/28/08
to Gears Users
I have an imate jama running Windows Mobile 5 in Bangalore, India. I
am unable to get Gears (version 0.4.15 wince) to return the location
of my mobile phone. I get an error which reads something like, "The
provider at www.google.com/loc/json is unable to get a good position
fix". The error code is 3 in the error callback for
getCurrentPosition.

Could you please let me know how to overcome the error?

I have an external GPS receiver connected thru bluetooth. Other
applications are able to retrieve position info thru the GPS
receiver. My understanding is that Gears should be able to retrieve
the location info even without the GPS receiver, while in my case I am
unable to get the location inspite of the GPS receiver being present.

Any help will be appreciated.

Ben Lisbakken

unread,
Aug 29, 2008, 4:58:32 PM8/29/08
to gears...@googlegroups.com, Steve Block
I am not sure what the answer to your question is, but Steve Block might be able to help.  He should be back in 3 days.

-Ben

ind.techie

unread,
Sep 4, 2008, 2:51:56 AM9/4/08
to Gears Users
Is Steve Block back?

Well some more info if its useful in solving this problem.

Will the GeoLocation api work from desktop computers as well? I
wasn't sure however gave it a try. I installed the desktop version of
Google Gears on my Windows XP SP2 IE 6. After successful
installation, when i try the getCurrentPosition sample, I get the same
error "network provider at www.google.com/loc/json did not get a good
position fix". Does GeoLocation use IP 2 location or something
similar? How accurate is this? And why is it not working for me? Is
it because I am in Bangalore, India? Or is it something else?

Also, why doesn't GeoLocation work on my mobile, while rest of Gears
works? The GPS receiver is active and working with other apps.

Please let me know how I can get this useful service to work.

Regards,
Ram

M.Kurabi

unread,
Sep 4, 2008, 7:43:41 PM9/4/08
to gears...@googlegroups.com
Ram,
 
I too have issues getting the Geolocation API to work with a windows mobile GPS enabled device (built-in). Google Maps and other GPS software work fine. But I can't seem to get the API to pick up the built-in GPS.
 
With that said, is there anyone that got the geolcoation api to work with a GPS?
 
regards,
 
Mojo

 

Steve Block

unread,
Sep 8, 2008, 9:52:28 AM9/8/08
to Gears Users
Hi,

Gears can use a number of sources ('location providers') to try to
obtain your position. These include GPS or a server-based location
service. The getCurrentPosition and watchPosition methods support an
optional parameter of type PositionOptions which lets you specify
which sources to use. See http://code.google.com/apis/gears/api_geolocation.html
for details.

With regard to getting a position from GPS, first make sure that
PositionOptions.enableHighAccuracy is set to true to instruct Gears to
use the GPS if present. Second, make sure your GPS is configured
correctly. Gears uses Windows Mobile's 'GPS Intermediate Driver' to
access the GPS. This should work with both onboard and bluetooth GPS
units, but may need configuring. See http://blogs.msdn.com/windowsmobile/archive/2006/06/07/620387.aspx
for details.

By default, Gears also sends a request to a network server to get a
position fix using your device's IP address and any cell ID data (if
available). The default server is one provided by Google, but you can
set the server that gears should use by setting
PositionOptions.gearsLocationProviderUrls. You also can set this to
null to prevent the network request altogether.

Use of a network server means that Gears should be able to get a
position fix on a desktop computer, by using the IP address. The
accuracy is around 100km. However, it's possible that the Google
server can't locate your particular IP address, hence the error
'Network provider at www.google.com/loc/json did not provide a good
position fix'. We're continually adding to and improving our database
of known IP addresses.

Let me know if you continue to have problems.

Steve

ind.techie

unread,
Sep 9, 2008, 7:35:27 AM9/9/08
to Gears Users
Hi Steve,

Thank you very much. It works now both on my desktop and my windows
5 mobile. Its probably the PositionOptions parameter that did the
trick. I had been using some custom scripting previously without the
3rd parameter in getCurrentPosition. Now it works both with
http://code.google.com/apis/gears/samples/hello_world_geolocation.html
and my custom scripts.

On my mobile I have tried with and without the bluetooth GPS
receiver and it works in both cases. And as expected, the position
info is more accurate with GPS. BTW, the default sesttings for
gearsLocationProviderUrls is what i used.

Thanks once again.

Regards,
Ram

kuba

unread,
Sep 14, 2008, 5:21:27 PM9/14/08
to Gears Users, jak.za...@gmail.com
Hi,

Does it mean that hardware port has to be set? I use HTC P6500 and I
can't set it up. I'm not sure if it can be set. Is there any way to
use GPS program port?

Thanks,
Kuba

On 8 Wrz, 15:52, Steve Block <stevebl...@google.com> wrote:
> Hi,
>
> Gears can use a number of sources ('location providers') to try to
> obtain your position. These include GPS or a server-based location
> service. The getCurrentPosition and watchPosition methods support an
> optional parameter of type PositionOptions which lets you specify
> which sources to use. Seehttp://code.google.com/apis/gears/api_geolocation.html
> for details.
>
> With regard to getting a position from GPS, first make sure that
> PositionOptions.enableHighAccuracy is set to true to instruct Gears to
> use the GPS if present. Second, make sure your GPS is configured
> correctly. Gears uses Windows Mobile's 'GPS Intermediate Driver' to
> access the GPS. This should work with both onboard and bluetooth GPS
> units, but may need configuring. Seehttp://blogs.msdn.com/windowsmobile/archive/2006/06/07/620387.aspx
> for details.
>
> By default, Gears also sends a request to a network server to get a
> position fix using your device's IP address and any cell ID data (if
> available). The default server is one provided by Google, but you can
> set the server that gears should use by setting
> PositionOptions.gearsLocationProviderUrls. You also can set this to
> null to prevent the network request altogether.
>
> Use of a network server means that Gears should be able to get a
> position fix on a desktop computer, by using the IP address. The
> accuracy is around 100km. However, it's possible that the Google
> server can't locate your particular IP address, hence the error
> 'Network provider atwww.google.com/loc/jsondid not provide a good

Steve Block

unread,
Sep 23, 2008, 12:34:12 PM9/23/08
to Gears Users
Note that this article - http://msdn.microsoft.com/en-us/library/bb158600.aspx
- discusses how to configure your GPS to use the GPS Intermediate
Driver, including how to do so on WinMo 6 Standard.

Steve
Reply all
Reply to author
Forward
0 new messages