jroal / a2dpvolume

Automatically exported from code.google.com/p/a2dpvolume
http://jimroal.com/slist.htm
95 stars 33 forks source link

Does not start a new location listener to capture best location #2

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
Right now the program captures the most recent and best locations.  However, 
that is only as good as the last location request.  So, if you don't have 
another program requesting a location (such as maps, navigation, etc) then your 
location is not very good.  The program works fine if you have maps or 
navigation (or any other program that request locations often).

To fix this I just need to implement a listener that requests location updates 
quickly and returns when the location is within some tolerance (say 10m) OR a 
timer has expired.  The deregister the listener.

Original issue reported on code.google.com by JimR...@gmail.com on 10 Oct 2010 at 3:28

GoogleCodeExporter commented 9 years ago

Original comment by JimR...@gmail.com on 10 Oct 2010 at 3:29

GoogleCodeExporter commented 9 years ago

Original comment by JimR...@gmail.com on 11 Oct 2010 at 2:35

GoogleCodeExporter commented 9 years ago
I finally fixed this.  It now launches a GPS location listener on disconnect.  
It gives it 15s to find a good location (within 20m accuracy).  The old 
location methods are still in place.  On disconnect it captures the latest and 
most accurate locations.  However, if the GPS is able to get a better location, 
the old one is overwritten with the new GPS data.  So, it will try to get the 
best location but it will not kill your battery if it can't get a good location.

Original comment by JimR...@gmail.com on 16 Oct 2010 at 4:06