Deep understanding of Android (1) __ System architecture

Source: Internet
Author: User

  Recently has been worrying about Android system-level development, a lot of things foggy, or feel that the basic knowledge is not solid, so, thinking repeatedly, or decided to seriously read the "in-depth understanding of Android Volume I, II", recently deep in hand a "deep understanding of Android Volume III" , I hope that in the process of study, will write down notes, with the Android enthusiasts to learn and progress together.

Let's get down to the chase.

--------------------------------------------------------------------------------------------------------------- --------------------------------------------------------------------------------------------------------------- --

1. Android System Architecture

            

The Android system can be broadly divided into four layers:

Android system (from bottom to top)
Linux kernel layer: contains Linux kernel and a series of drivers
Libraries Layer: This layer provides dynamic library (also called Shared library), Android Runtime Library, Dalvik virtual machine, etc., this layer is written by C, C + +, so you can simply consider it as a native layer
Framework Layer: Most of this layer is written in the Java language, it is the cornerstone of the Java world on the Android platform
applications Layer: These are the applications that interact directly with the user, and they are all developed in Java

One of the biggest features of Android is that it builds a Java world that is clamor by Java developers, but the Java world is not a castle in the castles, it relies on the native world (a world that Google tries to hide), and the interactions between them are as follows:

             

To illustrate this diagram:

(1) Java has platform-independent features, but the isolation between Java and the specific platform is implemented by the JNI layer, and Java is done by calling the JNI layer to invoke system calls in the Linux OS.

(2) The native layer provides a strong support for the efficiency and stability of the whole system. In general, the Java world interacts with the native world through the JNI layer through the IPC, while the most mysterious IPC method on the Android platform is binder. In addition, sockets are commonly used in IPC mode.

  This post and subsequent studies will be centered around the following architecture:

            

Mainly includes:

1. Native Layer: init, audio system (including Audiotrack, Audioflinger and Audiopolicyservice), surface systems (including surface and Surfaceflinger), Common classes (including Refbase, SP, WP, etc.), Vold, and Rild.

2. Java Framework layer: includes zygote, system_server, and common classes in Java (including handler and looper, etc.).

3, Java application layer: including Mediaprovider and phone.

  

Deep understanding of Android (1) __ System architecture

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.