weird GPS behavior

I have noticed a weird GPS behavior when using both Position.enableLocationEvents and Activity.info for GPS data. First I have a view that requests continuous GPS updates via Position.enableLocationEvents(Position.LOCATION_CONTINUOUS, myMethod); and a bit later I stop these requests with a call to Position.enableLocationEvents(Position.LOCATION_DISABLE, null);. The weird behavior occurs when starting an activity, because the activity.info won't update info.currentLocation anymore (info.currentLocationAccuracy equals 1). I should mention that everything works fine in the simulator and the bug happens on my fenix 3.

  • When you call LOCATION_DISABLE, you are turning of GPS on the device, so Activity.Info.currentLocation stops updating and the quality becomes "last known" (it's not getting any new data).  That's expected.

    The sim is a bit different, as when you play back a fit with GPS data or use simulated data, Activity.Info.currentLocation will actually start updating even people you enable GPS in your app,and the quality will be "good"  This is quite useful for apps/app types that don't control GPS themselves - a watch face or DF for example, where they want the location.  You can get the sim to act like a device by setting  Settings>GPS Quality in the sim to "Last Known", as you probably also what to use the quality when you do have GPS enabled.  "Last known" is telling you GPS is off, or has yet to get a fix on a real device