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
Contributor
stenhamm
Posts: 20
Registered: ‎03-01-2011
My Device: Not Specified

Re: Possible bug on Hotspot API automatic login to open WiFi network

Hi,

 

Well, not quite... That application enables your BB Bold to associate to hotspots. For example some Wi-Fi networks have this WISPr type of authentication along with normal landing page type of approach. Now this application of mine allowes your phone to programmatically choose a Wi-Fi network from surroundings and log into it. So it doesn't allow you to connect to your mobile with other devices... 

 

Br,

Teemu

Please use plain text.
New Developer
estebanuri
Posts: 28
Registered: ‎11-04-2009
My Device: Not Specified

Re: Possible bug on Hotspot API automatic login to open WiFi network

Continuing the theme of the hotspot...
I could not find a way to avoid the registration manually every time I want to subscribe to events of wifi.
The same thing happens to the guys in this thread.

http://supportforums.blackberry.com/t5/Java-Development/How-to-scan-for-available-networks-for-devic...

I tried to change the world, but I couldn't find the source code
Please use plain text.
Contributor
stenhamm
Posts: 20
Registered: ‎03-01-2011
My Device: Not Specified

Re: Possible bug on Hotspot API automatic login to open WiFi network

Ok, I don't fully understand what you are after, but I think one solution could be to divide your software to two parts. First part is background process that starts up when the device boots and the other part is ordinary UI application that does what ever you wish to do (and starts on users demand).

 

Now these two applications communicate by using system events instead of any interface. 

 

This is the way I have taken the whole Wi-Fi radio to my control and the end user needs to do that HotspotClient wizard only once. So, instead of registering your HotspotClient implementation just when you need that scan you would actually have it registered all the time and just poke it with system events when you wish to retrieve something.

 

Br,

Teemu

 

Please use plain text.
New Developer
estebanuri
Posts: 28
Registered: ‎11-04-2009
My Device: Not Specified

Re: Possible bug on Hotspot API automatic login to open WiFi network

I need to develop an application that obtains the same information that integrated Blackberry wireless-network application does. This is to scan APs, in a programatically way (eg. show a list of SSIDs, power signal).

I don't need to connect automatically.

 

I've tested on my device the code you posted, and it only receives the getSupportedNetworks callbacks the first time I run the application, and only if I put the application on background and I follow the configuration wizard for the wifi Hotspot. My device is BB9360 with OS7.1. The second time I run the application, it does not show the wizard, and I don't receive the getSupportedNetworks callbacks.


I've implemented a very similar sample code, that does a HotspotClientRegistry.add when application starts, and a  HotspotClientRegistry.remove when applications ends. In this way I can receive callbacks on every application run, but only if I follow the configuration wizard manually.

 

Br,

Esteban.

I tried to change the world, but I couldn't find the source code
Please use plain text.
Contributor
stenhamm
Posts: 20
Registered: ‎03-01-2011
My Device: Not Specified

Re: Possible bug on Hotspot API automatic login to open WiFi network

My application does that scanning on demand (not the one I was showing here), so I know it is possible to do that. And to achieve this I made two separate applications:

 

First:

Background application that is set up to start while the device boots up. This application implements the necessary Hotspot classes and registers itself to the system. Then this application has a interface that is working via global events. One of the interface commands is scan which effectively turns the radio off, then on after couple ms and then waits some time to receive couple of times that "getSupportedNetworks" call (it saves all seen networks to a data stucture). 

 

Second:

UI application that knows how to send the global event asking for scan to be done and functionality to receive the list when firts application sends it (and show it to user or whatnot).

 

I cannot provide the source code to this app because it does so much more than only scanning. Removing all other would be too big task for me now :/

 

Br,

Teemu

 

Please use plain text.
New Member
gregorydavis
Posts: 1
Registered: ‎05-18-2012
My Device: Not Specified

Re: Possible bug on Hotspot API automatic login to open WiFi network

[ Edited ]

stenhamm, do you plan to make your app available on AppWorld?  I want to buy it as long as the price is reasonable. I have been looking for this capability!

Please use plain text.