Welcome!

Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Java Development

Reply
New Contributor
Posts: 3
Registered: ‎02-08-2013
My Device: Curve 9320
My Carrier: Orange

BlackBerryLocationProvider

Hi all,

 

Just a quick question here on efficiency of use. I have an app that monitors the GPS. It has various checks it runs on the location at varying intervals.

 

My real question is, I wish to stop checking for a certain period of time, let's say 5 minutes, is it more efficient to call pause on the location provider, or call stop and then resume it 5 minutes later?

 

At the moment if I keep it hot the whole time the battery will drain in about 5 hours or so.

 

Just looking for some advice really!

 

Thanks

Developer
Posts: 19,636
Registered: ‎07-14-2008
My Device: Not Specified

Re: BlackBerryLocationProvider

As I understand it, and I have not tested so can't say for sure, 5 minutes is borderline, and certainly if you don't need a GPS location for a period that is longer than 5 minutes you should stop GPS and restart. 

 

HTH.

New Contributor
Posts: 3
Registered: ‎02-08-2013
My Device: Curve 9320
My Carrier: Orange

Re: BlackBerryLocationProvider

Thanks Peter, I'll give it a go with pausing first as 5 minutes will probably be the longest period the location is not needed for.
Developer
Posts: 19,636
Registered: ‎07-14-2008
My Device: Not Specified

Re: BlackBerryLocationProvider

That is exactly what I would do too.

 

Can you let us know if it does in fact extend the battery life?

New Contributor
Posts: 3
Registered: ‎02-08-2013
My Device: Curve 9320
My Carrier: Orange

Re: BlackBerryLocationProvider

I will indeed, hopefully be sorted by the end of next week with this app!