Yesterday we saw Android 5.1 make the rounds with a few official builds for Nexus devices. The next iteration of the popular OS brings new features and various improvements to the table and incorporated all of the patches and bug fixes from Android 5.0.1 and 5.0.2.
All and all, it is much more focused on updating Lollipop with new functionality and attending to some irritations, than the previous two builds and consequently comes with a few new APIs – API level 22 in Google talk. For a rundown of what is new on the user side of the build you can check our brief overview.
Naturally all of the changes need to be made available to developers, so apps can take advantage of the improvements and today this was achieved with the release of Android SDK 5.1. API changes are few, but do allow more flexibility in future applications. Android 5.1 now includes native support for multiple SIM cards. The SubscriptionManager class now has information on the currently active SIM, as well as methods for procedural switching and activation of one card or another.
Carrier Services is another novelty shipping with the new OS version. It is meant to simplify different provisioning tasks that carriers usually perform on their on-contract devices. The idea is that a regular application will now be able to perform most of these tasks. This could potentially eliminate the need to reinstall a lot of carrier content before shipping the devices and instead, have all the necessary settings and soft modifications delivered by an app on the Play Store, or another delivery system.
Security features have also been implemented to guard against malicious attack on the new API. An application will be able to do the aforementioned provisioning tasks only if it is signed with a certificate that matches the certificate in the device’s Universal Integrated Circuit Card (UICC). This should allow only your carrier to make such modifications.
The new SDK can be picked up today through the Android SDK Manager in Android Studio and requires Android SDK Platform-tools r22 or higher, as well as Android SDK Tools 23.0.5 or higher. As far as device builds go, currently there are factory images available for Nexus 5, 7 and 10 with builds coming for a range of Nexus devices within the next few weeks, including: Nexus 4, Nexus 5, Nexus 6, Nexus 7 , Nexus 7  (3G), Nexus 7 (2013), Nexus 7  (3G/LTE), Nexus 9, Nexus 9 (LTE), Nexus 10, and Nexus Player.
Source | Via