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: 7
Registered: ‎12-14-2011
My Device: 2010 - Bold
My Carrier: Vodafone In

Location API not working

I have registered location listener to get the periodic location update. I have configured BlackBerryCriteria as under,

 

criteria = new BlackBerryCriteria(GPSInfo.GPS_MODE_AUTONOMOUS);
criteria.setCostAllowed(false);
criteria.setHorizontalAccuracy(50);
criteria.setVerticalAccuracy(50);
criteria.setPreferredPowerConsumption(Criteria.NO_REQUIREMENT);

 

But it seems that Location API is giving error while trying to get location update. The error in the error log is like,

 

Stop GPS - process removed and all GPS session terminated for mode:2

 

After this, I'm trying to get the location update using Cellsite and it is working fine. I'm getting location data within 2-3 seconds in this case. But the data is not much accurate in this case. So, I don't want to use Cellsite data.

 

Can anyone guide me how to get location data with GPS_MODE_AUTONOMOUS. How to solve the error I'm getting and how to avoid it in subsequent location fix.

 

Device: 9800 Torch, Carrier: idea-India

 

Thanks.