Faster GPS Updates

Put problem concerning MapActivities, MapViews, Overlays and GPS in this forum.

Faster GPS Updates

Postby GonzoCSU » Fri Jul 29, 2011 5:57 am

I am developing a honeycomb app to map lines and points. I will be using an external precision GPS receiver running at 5Hz. So far I have been using "Bluetooth GPS" or "Bluetooth GPS Provider" to receive the NMEA strings from the GPS receiver. So my problem is my receiver is sending locations 5x a second but I am only getting a location update about every 10 seconds while moving 1 mph which works out to about once every 14 feet. Unfortunately NmeaListener seems to be broken in honeycomb so that is not an option (and I don't even know if that would help with this problem or not).

I am using the standard location setup
Code: Select all
        String context = Context.LOCATION_SERVICE;
        locationManager = (LocationManager) getSystemService(context);

        Location location = locationManager.getLastKnownLocation(provider);
        locationManager.requestLocationUpdates(locationManager.GPS_PROVIDER, 0, 0, locationListener);

I then save the location to the database inside the updateWithNewLocation() method. I tried writing a Runnable to run every 5 seconds which would save the location but this resulted in every 2-3 locations in the database being the same because the location had not updated yet.

So it seems like I have two choices here.
1. Figure out how to force the Android core system to update the location more frequently. This would be the preferred method as I don't really want to log multiple points if I am sitting still.
2. Write my own Bluetooth NMEA provider and feed it into my program. This seems like the most control but I have no idea where to even start on this task and I would rather not reinvent the wheel if I don't have to.

Does anyone have any ideas on how I could force faster updates or have another method of receiving locations besides what I posted above? There must be a way to do this, if you look at apps like "GPS Test" or "GPS Status" the locations update much faster than what I am seeing.
Once Poster
Once Poster
Posts: 1
Joined: Tue May 11, 2010 4:26 am
Location: Fort Collins, CO


Return to Map Problems

Who is online

Users browsing this forum: Yahoo [Bot] and 4 guests