Logo

HomeAboutCommunityDownloadDocumentationPlanet


Android Port

These build steps assume that you have set up a basic AOSP build environment as described in the Android Open Source Project pages.

Hardware

The repository has been tested on and has configuration for the Samsung/Google Galaxy Nexus, which at the time of writing this is the reference platform for Android development. It should be fairly straightforward to port to a Pandaboard, and just a little less so for other devices with ALSA support (it's mostly a matter of making sure the mixer paths are correctly configured or adding appropriate ALSA UCM configuration).

androgenizer

Get androgenizer, build it, and make sure the binary is in your path.

Get the code

This assumes you have a checkout of the AOSP code from Google upstream already.

$ cd <top-level-AOSP-source-dir>
$ wget http://people.collabora.com/~arun/android/local_manifest.xml -O .repo/local_manifest.xml
$ .repo/repo/repo sync

Compile

$ (assuming you've run envsetup.sh and lunch from the AOSP build instructions)
$ export PATH=$PATH:/path/to/androgenizer
$ make pulseaudio-aggregate-configure
$ (you will see a failure while configuring pulseaudio)
$ make libltdl
$ make pulseaudio-aggregate-configure
$ make

Running

When you flash and restart the system image, you are now running PulseAudio as a replacement for ?AudioFlinger. Various bits of functionality are available, and this is a moving target. The following are tested at the time of writing this section:

  • Audio playback for most apps using native Android APIs
  • Volume control
  • Switching of outputs depending on the device plugged in (headphones, headset)

To Be Done

The following pieces are either partially or not at all implemented

  • Audio playback API completeness: infrequently-used bits of the API (loops, markers, etc.) are not implemented
  • Calls: this is work-in-progress, but needs to be cleaned and merged
  • Policy: initial implementations of volumes and port switching are done. There are probably a lot of bits of policy that still need to be implemented for us to have feature/bug-parity with standard Android.
  • Audio record API: can be implemented fairly easily like the playback API was
  • Audio effects API (we don't support this in PulseAudio at the moment)

Misc

That's about it. Instructions on pulling powertop into the build are TBF.

Information on the porting effort and some performance numbers is at this blog post.