📜 ⬆️ ⬇️

Google I / O 2016: Android N and Android Ecosystem Details

Hi, Habr! Over the past year, Android users around the world more than 65 billion times installed applications from Google Play, created by developers like you. Today, Android is the most popular platform and operating system in the world, and of course, we work on it every day. As we promised in our global review of Google I / O 2016, today a post about the upcoming changes in N: new features and revised old ones, changes in the UI, VR platform and Android for wearable electronics are waiting for you under the cut.




Android N: N means New


The Android platform is developing at an incredible pace. Not so long ago, we introduced the new UI and the concept of Material Design, the new compiler ART, which took the place of the Dalvik virtual machine, introduced an improved sleep mode and energy saving, showed new APIs for the camera, payment system, biometric sensors ... And it seemed that for N there was no nothing that could really be a decent headline for news. However, the last I / O showed that Android has room to grow, and the number of changes is comparable with the transition of Android 2.3 => 4.0 or 4.4 => 5.0, and now it’s even difficult to choose what to tell first.
')

Android development directions


For Android N, we chose three main areas in which we made significant improvements in our mobile OS: performance, security, productivity (efficiency). At the same time, we tried to change the work of the system, starting from the needs of the users themselves and information about how they use the phone, what is important for them, what everyday problems they solve with the help of Android and mobile applications.

Performance


We have long improved the OpenGL subsystem, but in Android N we are taking a qualitative step forward by introducing support for the Vulkan API.

The main feature of Vulkan is that it allows you to control the GPU directly, reducing the overhead of the graphics subsystem and run the code on shader processors in the most efficient way.



Another nice bonus is the unification of the API with desktop technologies, which will allow developers to use the same code and resources on smartphones, computers (and, potentially, next-gen consoles). In addition, Vulkan has a smaller CPU overhead (that is, it doesn’t require as much CPU resources as OpenGL to draw each frame). The creators of games and three-dimensional applications will be able to increase the quality of the displayed image or raise the frame rate on an existing hardware.

The second important step in improving the performance of Android N is working on the program execution environment and the new JIT compiler. The update of Android Runtime introduced an increase in performance from 40 to 600% in various benchmarks, and the new compiler accelerated the installation of applications by an average of 75%.



At the same time, the features of the JIT compiler and the way it turns the .apk into an installed application made it possible to reduce the consumption of internal memory by installed applications by up to 50%.



In total, we have: a new graphics subsystem API, which brings console technologies to the smartphone; updated Runtime, which speeds up the work of applications; The new compiler saves space on the drive and increases the installation speed of the application. Not bad?

Security


In Android, elements such as SELinux, Boot Integrity checks, the ability to fully encrypt the media, have already been implemented, but security is never enough.



File encryption in contrast to block encryption allows you to better isolate individual processes and users in the system

Improving the security of the Media Framework - individual elements of the multimedia framework were moved to separate SELinux processes, since the Media Framework is one of the most widely used elements and can work with data whose security is in question.

And now - the most important thing. Android N will get a "feature" from Chrome OS: background system updates. N-based devices will have two system images: while you are working in one, the second can be updated in the background. The next time you boot the phone, it will select a proto image with a more recent version of the system. Thanks to file-level encryption, the new Direct Boot operating mode and two system images, you will not have to wait until the system is updated. A new JIT compiler will save you from many minutes contemplation of this picture:



Productivity


By themselves, improvements to the OS in the area of ​​“brute force” and security are good, but even better when it is complemented by a thoughtful and user-friendly interface, high-quality firmware, and what many users would describe as “intuitive”. Of course, behind all these concepts are hundreds and thousands of man-hours of work.

Start with multitasking. From the very beginning, multitasking favorably distinguished Android from competitors in the market - switching between applications in real mode, without losing data and not wasting time repeating actions already performed, brought Android closer to the “desktop” operating systems. The multitasking system has a lot of room for improvement, and we have improved it from version to version, and it is time to tackle the convenience of switching between applications.

We conducted a detailed study and found that the vast majority of users switch only between the 7 latest applications. In Android N, the system will hide from the list of recent applications that you have not opened for a long time, so finding the right one is not difficult. And according to numerous requests, we added the button “close all applications” up for nexus devices.

Android is increasingly becoming for the user a kind of personal time management center. Working meetings, plans for the evening, quick search and writing notes - all this often requires working with two applications at the same time. On tablets and smartpads, you can run two applications side-by-side (we also updated the API for Multi-window mode), but this is not always convenient, and simply unavailable for devices with a small display diagonal (not everyone likes “shovels”) .



Switching between the seven latest applications is a popular case-case, but even more popular, as you may have guessed, switching between two applications. Therefore, we decided to add a nice little thing that came from the "desktop" systems - a kind of simplified Alt + Tab: a double tap on the multitasking button cycles through the last two open applications.

Android N on TVs will receive a number of improvements in the UI, but one of the main features will be picture-in-picture mode, which allows you to work with the interface of various applications while watching your favorite shows.



One of the areas that is regularly undergoing refinement and improvement is the quick settings and notifications panel. In Android N, we added a direct response feature that allows you to respond to messages directly from the notification panel, without interrupting the current screen.



In addition, we simplify the management of notifications for each of the applications, so now you decide which notifications are important, which can be shown silently, and which can be completely hidden.


Well, to close the topic of productive work with Android, I would like our new killer feature. We want to make it easier for users to work with your applications, so that each developer finds his user. And we are well aware that there are a number of applications that in 90% of cases will not be used every day: well, if once a month or several times a year. This is not a reason to lose a potential audience of users. What if they could access one-touch services without first installing? Introducing Android Instant Apps - a fundamentally new approach to working with applications.

People learn about your services in different ways: find them in the Search, in social networks, instant messengers or get links to go to the application. Now, in any of these cases, they can easily log into the application - without having to install it or re-authenticate it. Parts of the application required for launch will be downloaded and launched automatically.

But that's not all! The Android Instant Apps feature is compatible with all Android Jellybean devices and later versions (4.1+) on which Google Play services are installed. That is, not the capabilities of the OS itself as such, but the method of delivering applications has been reworked. Android Instant Apps is an upgrade of your existing Android application, and not a separate program or module that the user needs. Naturally, if you want to get the benefits of Instant Apps, you will need to modify your application a little, but the changes are not as complex as they seem at first glance. To get the necessary documentation, take part in the early access program . And let your users find you!

What was known about Android N before Google I / O 2016


The first versions of Android N this year became available earlier than in the past. We provided early builds for testing to the developer community and collected a lot of useful feedback - for which we are very grateful to you. Without you and your feedback, we would solve many problems longer than we would like. Along with the early builds, we presented some minor improvements.

For example, a new design of the notification panel with a redesigned quick settings interface, designed to save screen space and simplify phone management; grouping of the same type of notifications from the same application; minor UI enhancements for tablets; change the settings interface; new design for the built-in keyboard; Unicode 9.0 support, as well as system APIs for supporting pressure sensitive displays.

One of the most important improvements in N that were available before Google I / O was the Doze 2.0 deep sleep system. The first version of Doze made its debut in Android 6 Marshmallow, it added new APIs to the system for interacting with the system when it was in the “deep sleep” stage and maximum energy saving. Batch verification of new information from the network, more rare wake-ups of the processor from the power-saving mode, minimization of background traffic, and other improvements worked when your smartphone remained motionless for a long time. Why waste precious battery power when nobody uses a smartphone?

For the year, the developers of the most popular applications added Doze support to their offspring, and it is time to take the second step - to make Doze work every time you turn off the display of your device. Most of the current applications can now work with energy-efficient system APIs to get updates from the network, so you won't miss an important message, and your smartphone will work even longer from a single charge.

Android N beta testing


The third preliminary version of Android N for developers can be safely tested on the main phone or tablet. To join beta testing, go to android.com/beta and launch Android N on one of the following devices: Nexus 6, 9, 5X, 6P, Nexus Player or Pixel C and Android One (General Mobile 4G). Test the beta release on the N platform and collect user feedback.

VR and Android


The Android system was created to work on different devices - smartphones, tablets, smart watches, in the car or at home. At the same time, the process of switching from one device to another is almost imperceptible. What next? We believe that soon the smartphone will become a powerful tool for learning about the world and consuming new types of content. However, until recently, the idea of ​​high-quality mobile virtual reality seemed impracticable in the Android ecosystem.

When we worked on N, we touched on many elements of the system (besides those described above): starting with how the operating system reads information from the sensors, and ending with how it transmits the image to the screen. All this was done to ensure that the quality of work in the virtual reality mode on Android was at a very high level. It is believed that the minimum comfortable delay for the perception of VR content is 25 ms (less is better), and the display refresh rate is desirable from 90 Hz. To achieve such results, we had to sweat.

First of all, we made a number of performance improvements that developers of VR content will notice, including rendering with a single array and exclusive access to CPU resources for VR applications. Now you can use in your applications the tracking system of accurate and smoothed head movements, as well as a special alert system that is used in the virtual reality system.

Secondly, we have worked on the system of displaying graphics on the screen. The response time to the Nexus 6P with the third test version of the firmware is less than 20 milliseconds. This is an incredible result for a mobile platform that was not developed directly for VR, and this is enough to give the user a sense of being in virtual reality. In sum, we have improved tools for developers and an operating system prepared for VR-content, which will work not only on new models and specialized hardware, but also on the existing generation of devices.

Thirdly, we added VR support to our main applications (and most importantly - to the application store), developed the Daydream software and hardware platform, and plan to seriously engage in the popularization of VR content. You can be among the first to enter this promising market - do not miss this opportunity. Start learning VR technology today with a beta version of Android N!

Android Wear 2.0: UI Changes and Independent Applications


On Google I / O, we also introduced Android Wear 2.0, the most significant update of the platform since its launch two years ago. We try not only to invent something new, but also purposefully improve products based on your preferences, experience of using our gadgets and needs that are not yet closed. Therefore, we carefully studied the wishes of users and developers, and based on them we updated the software. Now interaction with smart watches will become even more comfortable. Changes have affected the design of the dials, messaging and fitness monitoring.

We made several changes to the user interface and updated reference designs to make the use of your applications even more intuitive and their appearance attractive. If before the labels of any features or functions on the watch could be provided by the creator of the dial (and could not be provided), then now you can choose which modules to display information to combine with your favorite dial.

For developers in version 2.0, we added the ability to create independent applications that will have direct network access to the cloud using Bluetooth, Wi-Fi or a cellular connection. Since in this case your application will not depend on Data Layer APIs , it will remain fully functional, even if the associated mobile device is out of the coverage area of ​​bluetooth or is turned off altogether. You can read more about these and other news here .



Android Studio 2.2: a new markup editor, restriction markup, and more


Android Studio is an integrated development environment that allows you to use the Android N platform to access all new features most efficiently and quickly. At the Google I / O conference, we presented an update to version 2.2, another significant update in the development environment.

Its goal is to facilitate and accelerate application development through the use of new smart features. One of the most important is an improved markup editor and new markup restrictions. Firstly, you can no longer use XML to create markup, and secondly, new tools help you develop the interface at once for many excellent Android devices. Once you determine the optimal markup, we take over all the work of automatically calculating all the constraints. Thus, in all versions of your user interface on different screens, resizing will take place automatically.





All this - only a small part of the updates for Android, announced at the Google I / O conference. Over the course of three days, more than 50 sessions took place, and all of them are available on YouTube . We are very interested in how you will use all the new features!

Source: https://habr.com/ru/post/301904/


All Articles