Inside Android

Contact Us for Dates
3 days practical workshop for up to 12 people.
Only £1185
This course is intended for those who want to take an existing Android platform and customise or optimise it for their own needs. Attendees will gain an insight into the inner working of Android using a combination of theory and hands-on lab sessions. Customisations covered range from the simple, such as changing the boot animation, to the more complex such as adding native services and non-Android code. On the optimisation front, they will find out how to use the Android NDK to call C/C++ code from apps, including how to detect and use the NEON co-processor for compute-intensive operations.All example code is based on the Android Open Source Project using the current Ice Cream Sandwich release.

Layout

An essential part of the training are the lab sessions, which take approximately 50% of the time. We normally work in pairs using a modern development board. Each group will also need a laptop or desktop to run the system development tools. We will provide a bootable USB memory stick with an appropriate version of Linux and Android development tools, so there is no need to install Linux beforehand.

Who it is for

Software engineers and system architects

Training Course Prerequisites

  • A good understanding of the C language and familiarity with Linux development and command-line tools. A working knowledge of Java is useful.

Chapters

Chapter 1 Introduction to Android

  • Getting started with the SDK and emulator
  • Using adb (Android debug bridge) to run a shell on the emulator
  • Getting the source code: the Android Open Source Project (AOSP)

Chapter 2 Internal and external storage

  • Files and directories: what goes where
  • File storage media: raw NAND flash, SD cards, eMMC and USB storage
  • The RAM disk

Chapter 3 How Android boots

  • Types of boot loader; the fastboot protocol
  • Main and recovery boot partitions
  • The init program and the init.rc boot script: detail of the boot stages and how to add your own native services
  • System properties: how they are defined and how to change them
  • Zygote and system server
  • Starting the Android framework: how to define your own launcher

Chapter 4 Anatomy of an App

  • Application components: activities, services, broadcast receivers and content providers
  • Using the SDK to create and run a simple Java application
  • What goes into the apk file
  • How Android uses transient user IDs for security
  • Life cycles of components
  • The Android logger (logcat)
  • Low memory handling

Chapter 5 Native code

  • How to use the NDK to write optimised functions in C and C++
  • How to detect and use the NEON co-processor to optimise data manipulation
  • Native libraries and the Bionic C library
  • Strategies to integrate non-Android native code

Chapter 6 Debug tools

  • adb in detail
  • Using the Dalvik Debug Monitor Server (DDMS) to see what is going on
  • Using gdb to debug native code
  • Capturing and analysing application and kernel crashes

Chapter 7 The kernel interface

  • Overview of the Android HAL (Hardware Abstraction Layer): lights and sensors
  • OpenGL ES libraries
  • The input layer: touch screens, mice, keyboards and keypads
  • Power management: using wakelocks to stay awake