j2ME setLocationListener()

Posted by Jeff Catania on Stack Overflow See other posts from Stack Overflow or by Jeff Catania
Published on 2010-06-01T14:29:41Z Indexed on 2010/06/01 14:33 UTC
Read the original article Hit count: 295

Filed under:
|
|
|

I'm programming a GPS tracking system using the Motorola i335 running on Sprint's IDEN network. I'm using the javax.microedition.location api to find the GPS coordinates. To set up the updating, you use the [setLocationListener][1] method. I originally tried passing (listener,2,1,1). However there was too many invalid locations being received (where the GPS could not get the fix in the specified time), so I changed the parameters to (listener, 20, 20, 1). Now the system barely throws any invalid locations. My goal is to get the fastest number of updates that are realistic. Have any of you found a happy medium for parameters of this method?

[1]: http://www-users.cs.umn.edu/~czhou/docs/jsr179/lapi/javax/microedition/location/LocationProvider.html#setLocationListener(javax.microedition.location.LocationListener, int, int, int)

© Stack Overflow or respective owner

Related posts about java

Related posts about geolocation