Android Tutorial

Software Setup and Configuration

Android Studio

File Structure

Components

Core Topics

Layout

View

Button

Intent and Intent Filters

Toast

RecyclerView

Fragments

Adapters

Other UI Component

Image Loading Libraries

Date and Time

Material Design

Bars

Working with Google Maps

Chart

Animation

Database

Advance Android

Jetpack

Architecture

App Publish

App Monetization

Android System Architecture

Android is an open-source operating system developed primarily for mobile devices, although it's now used in various devices such as tablets, televisions, cars (Android Auto), and wearables (Wear OS). Android's system architecture can be understood at multiple layers. Here's an overview:

  1. Application Layer:

    • Applications: These are apps that the user directly interacts with like the Dialer, Web browser, or Games.
    • Application Framework: It provides high-level services to applications in the form of Java classes. Examples are the Activity Manager (which manages the application lifecycle), and the Content Providers (which allow data exchange between applications).
  2. Library Layer:

    • Surface Manager: It handles the display composition and manages surfaces in a Z-order.
    • Media Framework: Supports playback and recording of audio, video.
    • SQLite: A database engine used for on-device storage.
    • WebKit: The engine that powers most mobile web browsers.
    • OpenGL|ES: Graphics API for rendering 2D and 3D graphics.
    • FreeType: Bitmap and vector font rendering.
    • SSL: Libraries used for Internet security.
    • libc: The standard C library.
    • Bionic libC: Android's implementation of the C library.
  3. Android Runtime:

    • ART (Android Runtime): This is what replaced the Dalvik virtual machine in later Android versions. ART compiles apps using AOT (Ahead-of-Time) compilation upon installation which generally results in faster execution and smoother performance.
    • Core Libraries: These are Java-based libraries that provide most of the functionality in the application framework.
  4. Hardware Abstraction Layer (HAL):

    • This layer provides standard interfaces that expose device hardware capabilities to the higher-level Java API framework. For instance, there would be a HAL for the camera module, which would allow the camera application and camera-related features in the higher layers to interact with the camera hardware without needing to know the specifics of the hardware.
  5. Linux Kernel:

    • This is the foundation of Android��s architecture, which lies at the bottom of the stack. Android relies on the Linux Kernel for core system services such as security, memory management, process management, and the network stack. It also provides drivers for hardware, networking, and more.

The Android System Architecture can be visualized as a stack where the Linux Kernel sits at the bottom, the hardware abstraction layer above it, then the Android runtime and core libraries, followed by the application framework, and finally, the applications sit on top.

Over the years, Android's architecture has been evolving. Features like Project Treble were introduced to modularize the architecture further and make updates easier, separating vendor-specific changes from the core Android framework. Always refer to the latest Android documentation or trusted sources for updated and detailed information on Android's current architecture.