03-10-2010 10:03 AM
I know. A radio listener can do the trick.
However, here is what I am trying to get at. There are two level of WIFI connections. First, the device has been connected to the wireless router and has obtained an IP address. Second, the device has established connection to BIS which is indicated by the bright white wifi icon on the screen. I can use getWLANState to see if the WLAN is connected, but still don't know which stage of connection it is in. As far as the BB device is concerned, a lot of functions are not going to be available unless I am connected to BIS (say I don't have coverage, only WLAN).
03-10-2010 04:01 PM
You can use the CoverageInfo class to determine if the BlackBerry smartphone is connected to BIS or a BES.
There is no way to programmatically determine if the BIS/BES connections are going over the cellular network or over a WiFi network in the case that both networks are connected (i.e. device is connected to a WiFi router but has not established a connection to BIS/BES for least cost routing).
03-10-2010 04:52 PM
My application uses UDP. So BIS/BES connection is not required. However, I do want to determine which should be used, OTA or WIFI, during a session so the user experience can be as seamless as possible when transitioning from an outdoor area to indoors, or vis versa. I guess I can use the radio strengths as part of the decission making process.
03-15-2010 05:00 AM
Consider implementing your own switching logic independent of RIM's least cost routing for BES/BIS. Firstly, since you are using UDP, you are limited to Carrier TCP/UDP and WiFi, whereas BES and BIS transports can also go via the USB and Bluetooth, in addition to Carrier and WiFi routes. To make matters more interesting, consider the following:
1. BES and BIS transports are not available if the SIM/handheld is not registered/provisioned/permissioned for these services. You application should be able to work in these scenarios, since it doesn't need BES or BIS.
2. There could be carrier PDNs or WiFi networks where BES or BIS is blocked whereas your application's traffic is not, and vice a versa.