01
Jul
android_hotspot

If it's not already completely obvious, the L Developer Preview is shaping up to be an absolutely massive sea change for Android. While we've been treated to an entirely new design language called Material, a redesigned Recents screen, huge performance improvements, and over 5000 other new APIs and features for developers, it's easy to overlook plenty of exciting improvements that aren't quite as flashy. One such change was briefly mentioned by Dan Sandler during the "What's new in Android" session: Multi-Networking, the capability to maintain multiple network connections simultaneously.

Screen-Shot-2014-07-01-at-2.54.58-AM

Historically, Android's design philosophy about networking has dictated there should only ever be one connection to the Internet at a time. This may seem logical since maintaining extra connections tends to eat up a lot of battery, but there are times when it's useful. The new API allows developers to request a network connection with a specific set of criteria, which the ConnectionManager will attempt to provide. The options can be found in the NetworkCapabilities class, which currently offers 18 options including things like unmetered throughput, high-bandwidth, and carrier-specific services like MMS.

As a user, you might be wondering why developers may want to activate multiple network connections on your device. We already see some of this happening for activities like carrier billing or transmitting MMS messages, which are already handled by firing up cellular data for a short time. Other examples include maintaining a high-quality and consistent connections, which will be important for VoIP services like Skype where a seamless handoff between networks can prevent dropped calls. This may also enable the use of devices like Wi-Fi storage drives without completely cutting off data from hotspots or cellular connections, a problem I've discussed in a previous product review.

Here's the short introduction given at Google I/O 2014:

If you're a developer and this seems like something you could implement in your own apps, a few more details can be found on the API Overview doc.

Most competing mobile platforms like Windows Phone and Blackberry have nothing like Multi-Networking; even Apple only implements a couple of very specific scenarios. This probably won't be a widely recognized or acknowledged feature, but it gives developers enough access to make their apps even better and more fluid in ways that are not possible anywhere else.

Cody Toombs
Cody is a Software Engineer and Writer with a mildly overwhelming obsession with smartphones and the mobile world. If he’s been pulled away from the computer for any length of time, you might find him talking about cocktails and movies, sometimes resulting in the consumption of both.

  • Alexandre Leites

    One thing that I hate on Android is that once connected to a network, it doesn't change to a better one. I have a scenario where there are two different signals (per floor). I have the password of those wifis, but when I'm walking in and out of these floors, the signal don't change to the better one... I hate when I saw that my mobile is connected to a 1 bar WiFi when I have a full bar next to me.

    • http://www.androidpolice.com/author/cody-toombs/ Cody Toombs

      I see that all the time on my Nexus 5. However, my HTC One actually prefers a specific hotspot if it's within range and the signal is good enough. Sometimes it will switch back to its preferred network a while after I've manually changed it. Both behaviors are obnoxious, but I'm not sure which I dislike more.

      • Pierre Gardin

        Changing WiFi networks breaks TCP connections and they probably try to avoid that. This is solved by Google's QUIC BTW.

    • Nuno Guerreiro

      Your case is not a generic case, for you it's better that it switches, but what if... you have two networks, the first one is at the first floor and you have the Wifi password. You are connected.
      The second one, is a open public wifi, that you regularly connect but you also need to enter the wifi credentials, user and pass via a website, after the connection.
      In android, every time you switch ON wifi, it connects to a Wifi AP if you previously have connected successfully to that AP, right? Even if doesn't have an internet connection (cause needs to be authenticated after connected).
      In that case, what you ask, simply wouldn't be great cause the moment it will switch to a better wifi connection, but one that you need to provide a manual authetication, you will be cut off the internet...

      • Guest

        I don't like this kind of networks, because all of my gadgets (phone, laptop, tablet) always pick the weakest one of those networks. Of course, when I installed linux on my laptop, I can make my laptop to connect to particular BSSID, but not my phone/tablet.

        • awaaas

          sorry, wrong person.

      • Hsanchez957

        Couldn't this theoretically be solved by having a priority list of networks? Your trusted network would go above the public one and maybe there can be rules applied too. Rules such as excluding networks that require further sign-in procedures or something like that.

        • Nuno Guerreiro

          Exactly, with a thing like that, could solve many of this problems... maybe in Android 6.0... or in 5 years from now... lolol

        • Christopher Bement

          A way to auto-spoof those additional sign-ins would rock.

          • Robert Dietz

            Someone wrote a neat little app that does just that for my university's WiFi. You open it once, enter your account name and password, and from then on it automatically does the login bullshit for you in the background every time you connect to the network. Works pretty well. So it isn't impossible, someone just needs to write an app that lets you handle different networks in the same manner ;-)

      • mgamerz

        That's why you get WiFi guest login :) it auto logs you into those things. Its soooo nice at my university. No more terrible guest wireless, now authenticated wireless. The interface kinda sucks though .

      • xxTheGoDxx

        With the majority of tablets sold being WiFi only (I guess) it is a (more) common problem IMO. Most people probably use a tether to there phone while on the go but would like it to automatically switch to their router ones they are back home.

        Plus, WiFi might expand in bandwidth but for many decreases it's range with 5 GHZ and more networks. So having multiple networks at home to cover every corner of ones space will surely become more common.

        And as mentioned by others, it could be veeeerrryyy easily fixed by allowing a priority flag in the WiFi settings.

    • Mario J

      Have you tried checking the 'Avoid poor connections' setting under the Advanced WiFi menu? That might help with your use case

      • Sukumar

        This will use mobile data instead?

    • chrulri

      Your problem is, that these wifis dont have the same SSID and/or are not operating on the same channel(s) using the same encryption and wifi standard.
      If all these parameters match, wifi devices will hop seamlessly between access points like they do between cellular towers.

      • awaaas

        I don't like this kind of networks, because all of my gadgets (phone,
        laptop, tablet) always pick the weakest one of those access points. Of
        course, when I installed linux on my laptop, I can make my laptop to
        connect to particular BSSID, but not my phone/tablet.

      • xxTheGoDxx

        But that wasted bandwidth because of the interference from multiple networks on the same channel! They should just add the option to set priority's instead.

    • someone755

      If the connection still works on that one bar, I don't see an issue.
      If you do, just change the network. Or find (or make) an app that does that for you.

      • xxTheGoDxx

        One bar gives you way less bandwidth than five and doing it manually is a shit poor solution. This should be an OS feature, period!

        • someone755

          I saw a "wireless router" that costs $300, but if you have more of them set up, any device will automatically connect to the better connection (without the connection ever being interrupted).
          So it would seem that your routers should get tweaked rather than Android.
          If you're interested, I can find it for you. It's an "enterprise" product, that's why the price is there, but it works very well as far as the reviews go.

    • Sergii Pylypenko

      Switching to a different access point will break all active network connections, that's why it's not done automatically. Some apps can handle that, others will show you errors.

  • r0l

    EyeFi needs to implement this. Make their camera to phone transfers so much better if you could keep your Internet connection.

  • Steve Birchfield

    I am glad to see this being built in. I use an app called Wifi-Prioritizer to deal with multiple wifi networks I have in my house between floors but some apps do not like the hand off. Maybe a native approach will work better.

    • Steve Freeman

      A lot of apps (mostly games, probably) don't like the hand-off. It's annoying as hell.

  • Eduardo Mateos

    Is this implementing WiFi roaming? (802.11k and 802.11r)

  • black

    I can already see these apps getting blamed for high data usage. Users are just dumb, most of the time.

  • http://galaxynote3tips.blogspot.com/ Martens Nkem

    Really, SYMBIAN has had this for ages..It's a damn shame, that humanity needs to go backwards to go forwards

  • jamaall

    I wish I could tell my phone to use LTE sometimes... It likes to switch to 3G or 1X, while I barely get any connection, when LTE works fine in that area. I used to force it using Phone Testing in the dialer, but that's been removed in kit kat.

  • Leif Sikorski

    This would be nice for remote camera control apps. Being connected with the camera via wifi and still be able to share and upload the pictures via 3G/LTE would make the workflow much easier.

  • Steve Freeman

    This will be awesome. I've just started leaving my WiFi off almost all the time, since anytime I get to the edge of WiFi coverage, anything I'm trying to do on my phone just hangs until I get far enough that it actually drops the connection.

  • My1

    I hope that will finally kill my "wifi trolling" at home. since our cable internet is in the cellar and I am in the roofI just barely have wifi which I obviously dont like, so I set up another wifi on top here and I ALWAYS have to switch manually when going to the other side of the house...

  • Sergii Pylypenko

    Now ads inside apps will be able to bypass Adblock/AdAway, by requesting advertisement data to always be routing through cellular connection.

  • xxTheGoDxx

    Another long overdue improvement would be to not treat a Wifi hotspot (provided by another Android device) as a cellular network instead of a Wifi one. What I mean by that is that apps right now don't have a way to know if the connected Wifi on an none cellular tablet is an actual router (with an unlimited date plan) or an hotspot on an smartphone. All this clever checkboxes allowing you to only download updates and content while connected to a router are basically worthless on a Wifi only tablet.

    • http://www.androidpolice.com/author/cody-toombs/ Cody Toombs

      Actually, there is a way for apps to determine if they are connected to a wi-fi access point that is tethering over a cellular connection. Not all tethering apps do this, but some will make a broadcast to indicate their status. I'm not sure if it's specifically identified as tethering over cellular or if they simply identify themselves as metered networks, but the information is there.

      The issue you should be complaining about is that most operating systems and apps don't check to determine if they are connected to such networks. Chrome OS already refuses to download updates on a metered connection (link), and I thought I remember reading that Windows 8 was going to do the same in the future, but this doesn't mean apps will adopt the same policy.

  • http://www.elijahlynn.net/ Elijah Lynn
  • Brad

    Can someone explain the implications of the "unmetered throughput" option? Does that mean an app can use bandwidth but not report consumption the system?

  • Arron Hall

    I don’t bother much about the specs and features of Android L. I just want that it must rectify the entire problem including quick battery drainage in my Nexus 5 that I am facing from last 5 months even after updating the Android 4.4.4 version. To overcome this issue from my end I installed a wireless car charger dock to keep its battery fully charged even on the go.