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
Developer
Posts: 44
Registered: ‎06-16-2009
My Device: Not Specified

LocationProvider - Cell Site Criteria

Alright, my first post!  I have been reading the forums and working on Java/BB development since last November.  Thanks for all the information I have found so far.

 

Now, to my question..I have been spinning my wheels on this for a long time.  Any help would really make my boss happy!

 

Device Info:

Blackberry Bold 9000 smartphone (3G, WI-FI)

v4.6.0.167 (Platform 4.0.0.157)

Not Enterprise Activated

 

Mobile Network:

AT&T

-70dBm

 

The app I have written requires the use of 'Current Location' features. We have found Autonomous Satellite connections are really lousy indoors (of course they are lousy, would you put your DirecTV satellite receiver in your house? no!).  It doesn't work at all especially deep inside offices or buildings.  Very, very rarely do we get lat/lng coordinates from inside a building using autonomous satellite criteria.

 

So, then we started researching Cell Site location providers.  There is a great section in the developer guide titled "Get location information from cell site towers."

 

When I use the Criteria specified in that section, my LocationProvider always returns null on the device    See code below:

 

Get Cell Site LocationProvider :

 

public static LocationProvider getCellSiteProvider() throws Throwable { Criteria criteria = new Criteria(); criteria.setHorizontalAccuracy(Criteria.NO_REQUIREMENT); criteria.setVerticalAccuracy(Criteria.NO_REQUIREMENT); criteria.setCostAllowed(true); criteria.setPreferredPowerConsumption(Criteria.POWER_USAGE_LOW); criteria.setAddressInfoRequired(false); criteria.setAltitudeRequired(false); criteria.setSpeedAndCourseRequired(false); LocationProvider lp = LocationProvider.getInstance(criteria); return lp; }

 

The LocationProvider calling code:

 

 

LocationProvider provider = null; Location location = null; try { EventLogger.logEvent("get cell site provider", EventLogger.ERROR); provider = GpsUtils.getCellSiteProvider(); // method above

if (provider != null) { EventLogger.logEvent("get loc from prov", EventLogger.ERROR); location = provider.getLocation(20); } } catch (Throwable t) { t.printStackTrace(); }

 

 When I test this on the device, the LocationProvider is always null.  I check the Event Log debug statements, and it never prints the 2nd debug statement.

 

 

 When I use autonomous, assisted, or null criteria, it works great, but only outdoors. Those criteria never work indoors.  We are hoping cell site criteria would be the answer to indoor location problems.

 

 


 

Developer
Posts: 1,415
Registered: ‎07-30-2008
My Device: Not Specified

Re: LocationProvider - Cell Site Criteria

Eh, you may have better luck with ATT but telling the verizon people how much time you wasted because they

quietly restricted access doesn't get a very empathic response...

 

Developer
Posts: 44
Registered: ‎06-16-2009
My Device: Not Specified

Re: LocationProvider - Cell Site Criteria

Okay, so you're saying that AT&T and Verizon do not support Cell Site location services?  This is completely a carrier issue? 

 

Hmmm...Any suggestions on how I explain that to my boss, CMO, and company Board of Directors?

Developer
Posts: 4,764
Registered: ‎07-21-2008
My Device: Not Specified

Re: LocationProvider - Cell Site Criteria

[ Edited ]

Print this out and show it to them:

 

http://www.blackberry.com/knowledgecenterpublic/livelink.exe/fetch/2000/348583/800332/800703/What_Is...

 

 

Verizon actually does support assisted mode, but you need to sign up as a Verizon developer to get access to their PDE info.

 

http://www.blackberry.com/knowledgecenterpublic/livelink.exe/fetch/2000/348583/800332/800703/What_Is...

 

Also see this article:

 

http://www.blackberry.com/knowledgecenterpublic/livelink.exe/fetch/2000/348583/800332/800703/What_Is...

 

Message Edited by RexDoug on 06-16-2009 11:14 AM