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: 237
Registered: ‎07-20-2010
My Device: Not Specified

how to: get nearby cel tower ids?

How can I get the ids of nearby cel towers?  I can get the one I'm connected to by:

GPRSInfo.getCellInfo().getCellId( );

but i would like to find several to do some geolocating - I have a database of cel tower ids and locations - so I guess I can just take an average latitude and longitude to estimate my users location.

 

Any ideass?

 

i am doing this for jde4.5 and lower devices.  for 4.6+ I use the apis for this stuff.

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

Re: how to: get nearby cell tower ids?

Sorry don't know the answer to your question but a comment intrigues me. 

 

I didn't think it was possible in any API to find out the cellid of any but the connected cell site.  But you say: "for 4.6+ I use the apis".  How do you do that?

 

Developer
Posts: 237
Registered: ‎07-20-2010
My Device: Not Specified

Re: how to: get nearby cell tower ids?

I meant that I just used the later APIs to get the location rather than using my own database driven solution. Though I guess that only works with version jde5+.

http://docs.blackberry.com/en/developers/deliverables/8106/Get_location_info_cell_site_towers_465506...

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

Re: how to: get nearby cell tower ids?

And it doesn't work for me in those devices either....

 

Anyway as far as I am aware, in all devices, it is only possible to get the currently connected cellid.

Developer
Posts: 237
Registered: ‎07-20-2010
My Device: Not Specified

Re: how to: get nearby cell tower ids?

oh well, just have to go with one tower then i guess. 

thanks.

Developer
Posts: 237
Registered: ‎07-20-2010
My Device: Not Specified

Re: how to: get nearby cell tower ids?

unless I can break my connection, and reconnect a bunch of times, that might get me in touch with several towers - then take an average latitude  n longitude.

What do you think?

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

Re: how to: get nearby cell tower ids?

I think that device will still only connect to the strongest one. 

 

I have toyed with the idea of running a little timer and picking up cellid changes over time but I'm not sure that helps.