Saturday 14 March 2015

Android Lollipop And Material Design

Android Lollipop

David Briddock investigates what’s different about Google’s Android Lollipop

Recent figures confirm that these days it’s Android devices that dominate the smartphone and tablet marketplace. In fact, Google’s Android operating system has secured over 80% of the total smartphone space, dwarfing iPhone sales, and Android smartphone shipments for 2014 are expected to top the one billion mark. This year’s sales will be equally strong.

Meanwhile, Android tablet shipments exceeded 120 million in 2013 and are far higher still for 2014. Once again, Apple’s iPad came a distant second, and other platforms hardly feature at all. And to cap it all, Google’s Play store now has as many apps as the Apple App Store.


New Version


But in the tech world nothing stands still. Now there’s a new release to replace the previous version, 4, which was more commonly referred to as KitKat. Version 5, also known as Lollipop, is a major update, so as you’d expect, there are plenty of new features and functionality on offer.

But there’s more. The user interface experience has been re-engineered from the ground up. In fact, Lollipop ushers in a brand new and radically different interface design paradigm. Google calls this new interface vision ‘Material Design’.

We’ll take a detailed look at Material Design shortly, but first let’s investigate some of the new features in Android Lollipop.

Improved Usability


Firstly, many apps exhibit a small yet noticeable increase in performance. This is largely down to optimisations in Lollipop’s new Android Runtime (ART), a 64-bit compatible replacement for the previous Dalvik implementation (see ART boxout).

However, as far as Android games are concerned, the majority are written with the Native Development Kit (NDK). This means they use C++ libraries and precompiled executables instead of ART or Dalvik bytecode, so unfortunately they won’t benefit directly from ART technology.

Multitasking control has also been improved. The ‘Recent Apps’ facility has been replaced with ‘Overview’, which displays all the background running apps as a card stack. It’s slicker in operation and so much easier to shuffle to the app you’re after.

Ever better, the ‘Overview’ display shows individual tasks within a single app, so if you’re say in the middle of writing a Gmail email but also checking your inbox, it will display task cards for each task.

Android notification settings are applied from the Menu/Sound and Notification/App menus, rather than configuring similar settings on each separate app. In the new ‘Priority’ mode you can select which notifications you’ll hear or see.

Fine-tuning options allow call and text notifications to be restricted to a discrete list of people. In addition, there’s a ‘Do Not Disturb’ mode for those who wish to set aside periods of uninterrupted focus and concentration.

Battery Life


Battery life is something that everyone notices and often has a good moan about too. The good news is that Android Lollipop should extend the working duration of each battery charge.

Google developers considered the battery life impact of each core Android app, module and operating system function. See for yourself how good a job they’ve done by opening the new Battery Historian feature. To take maximum advantage of the new power-sipping features, switch your Lollipop device into Power Saver mode.

Security


In addition to pass codes or passwords, you can now optionally unlock a device using face recognition, namely the bioverification ‘Trusted Face’ feature. Alternatively, you can unlock it with a previously paired Android device – for instance, a smartphone or smartwatch.

A more generic pairing capability allows both Bluetooth devices and NFC tags to be recognised, so just a cheap and simple wristband could be all you need to unlock any Android Lollipop gadget you own. And, of course, face recognition or dedicated device pairing is much faster than entering pass codes or passwords.

Another new security feature ensures all your data is now encrypted by default, so if your device is lost or stolen, someone needs a password to see your data. This encryption does result in a small system performance hit, but with today’s multi-core processor hardware, there’s invariably more than enough power to cope.

Android TV


Android Lollipop also supports TV via the Android TV service. This isn’t too surprising after the popularity of Chromecast and Google’s new Nexus Player (google.com/nexus/player). It delivers TV, films, games and so on right onto the big screen. Press the home button and you’ll return to the standard Android display.

Android TV has a voice interface, so you can search for something on a smartphone when connected to the Android TV, and you’ll have the option to watch the video either on Google Play or any other compatible app.

Android TV appears to have been endorsed by some big names, with offerings from Sony, Philips and Sharp, while Asus and others are promising to release Android TV compatible set-top boxes.

Google Chrome OS Interaction


At the 2014 Google I/O conference, Google’s Android and Chrome chief, Sundar Pichai, announced an array of new features designed to consolidate the Android and Chrome OS user experiences.

For example, there’s a facility to automatically unlock a Chromebook or Chromebox when your Android phone is nearby. Behind the scenes, it uses Bluetooth to access your smartphone’s Google account credentials. When activated, just having your Android smartphone in your pocket means you’ll be able to start immediately, avoiding a tedious manual sign on.

Communication events from your Android phone can appear in real-time on your Chrome OS device, so you’ll see incoming calls notifications, scan text message contents or even take calls without having to continually break away from the large screen to check your smartphone. You can even see that your phone’s battery is about to expire.

And an Android smartphone or tablet can act as a Chromebook or Chromebox remote control, which is particularly useful when the device is operating as an audio or video media player.

Material Design Overview


Google’s goal is to develop a single underlying system that allows for a unified experience across all platforms and sizes of device. But what does ‘Material’ actually mean? Well, Google says Material is a metaphor for a unifying theory based on space and motion. The material itself has a tactile reality, in the same way paper and ink does, but technology adds an element of magic.

With Material Design, surfaces and edges provide familiar visual cues, but with software that makes it easy to go beyond the rules of our physical world. Lighting, colour, texture and movement all help to convey how interface objects relate to each other and interact.

Google insists that Material Design will feel more intuitive, but there’s a bigger idea at play here. A Google master plan, if you like.

Material design is an attempt to remove the fragmented way Android looks today, to ensure consumers see a consistent interface and set of apps no matter which device they own.

Material Lighting & Colour


In a material environment, virtual lighting illuminates the scene, causing objects to cast shadows, both strong directional and multiangle soft shadows via ambient lighting.

Shadows result naturally from the relative elevation (z-position) between interface objects. An object with a higher z value casts a bigger shadow.

Material can be any shape and colour. Advanced features include applying bitmaps as an alpha mask to create colour tint effects at runtime. Content, displayed on the material, can also be in any shape and colour.

In practice, all material objects have a uniform thickness dimension of one, as content doesn’t increase the overall thickness.

Material Motion


Very early on, the Google design team realised motion provides meaning. Motion serves to focus attention and maintain continuity, with a subtle yet clear feedback.

This motion extends into the 3D space, so each object has x, y, and z dimensions and can move along any axis. However, typically z-axis motion is the result of user interaction.

Material can also change shape. It can grow and shrink, but not bend or fold. In addition, sheets of material can join together to become a single sheet, and when split, material can self-heal, so if a portion of material is removed from a sheet, it can become a whole sheet again.

All this means developers can create sophisticated animations for touch feedback, state changes, activity transitions and other interface events. These can be naturalistic animations with noticeably curved motion.

Many interface views, such as buttons, already have built-in animations, which are nevertheless fully customisable.

Material Design Guidelines


Such a radical new approach to interface design must be supported by clear documentation and informative tutorials. Google has stepped up to the mark with a comprehensive guide for visual, motion and interaction design across platforms and devices, so anyone can use material design in their Android apps by following these guidelines.

Android 5.0 (API level 21) and above embody new components and functionality. New elements include a theme, widgets for complex views, plus APIs for custom shadows and animations.

The dark and light material themes provide styles for apps and system widgets, but developers can set their own colour palette and specify default animations for touch feedback and activity transitions.

Android 5.0 provides two new card and list widgets with material design styles and animations. The newCardView widget displays important pieces of information with a consistent look and feel, while the newRecyclerView widget is an enhanced ListView that supports various layout types and has snappier performance.

Teething Troubles


With such a major update, it’s no surprise that early adopters found a few teething troubles. Early complaints included sluggish video performance, random crashes and virtual keyboard problems.

As you might expect, installing Lollipop on older devices with slower CPUs and less advanced graphics cards resulted in a nonoptimal experience. However, even Google’s own Nexus 5 smartphone suffered a serious wi-fi issue, which also caused battery life problems.

A more serious long-term issue is related to the new Android Runtime. To ensure faultless operation and to take full advantage of the enhancements, Dalvik apps need to be optimised for ART. So apps written for earlier versions of Android, and therefore older Dalvik implementations, may suffer problems. Problems that include crashes, which could result in losing your unsaved data or games status. In fact, in some cases it caused the Android OS to fail, requiring a full reboot.

This isn’t a two-minute code fix for an app developer. In fact, for a large and complex app, it may involve months of code changes and retesting, and of course, developers will still need to support Android devices running Dalvik, so now they have two completely different target execution environments.

Even now, it’s not clear how many of Google’s own apps have been optimised, let alone the millions of third-party Android apps.

Lollipop Updates


The good news is a 5.0.1 update in December 2014 did fix quite a few problems, and there’s been a steady flow of Lollipop-ready app updates at the end of 2014 and start of 2015.

Consequently, recent Android Lollipop blog postings and social commentary have been much more favourable; some owners appear to have enjoyed a 30% improvement in battery life since upgrading from KitKat and, as I write, it appears Lollipop 5.1 is due soon.

So the future of Android is already here, and regardless of these initial problems, there’s no going back. Lollipop, with its new look Material Design and enhanced Android Runtime, is here to stay.

In fact, indications suggest many of Material Design concepts are highly likely to appear in a future version of Google’s Chrome operating system, so we may well see a Lollipop-like user interface experience appear on those valuefor-money Chromebook laptops and Chromebox desktops.