2012年11月5日月曜日

Install Android Panda Linaro Evaluation Builds

Note: These instructions require a working install of linaro-image-tools. linaro-image-tools is developed and tested only for Ubuntu Lucid (10.04) or later. linaro-android-media-create is also developed and tested on Ark Linux dockyard-devel and Mandriva. Running on other configurations might or might not work. Feedback and contributions to support more distributions is encouraged!

External dependencies

Linaro uses a tool called linaro-android-media-create to install Android images. This tool is a part of the linaro-image-tools package. On an Ubuntu development host (10.04 or later), the easiest way to get these is:

$ sudo add-apt-repository ppa:linaro-maintainers/tools  $ sudo apt-get update  $ sudo apt-get install linaro-image-tools

This should ensure that you have packaged versions of all linaro-image-tools dependencies.

Quickstart

Our build page includes the commands you need to run to get each board up and running:

1. Go to http://android-build.linaro.org and find the build you're looking for.

2. Click on the build to find specific instructions for building that build.

  • Instructions are generally the same across builds, but they can vary.

3. Also on the build site are how to use each image.

Help!

If Something Goes Wrong or You Have Quesitons

Intro

Android images follow best upstream practices and come in form of three filesystem tarballs.

  • system filesystem (system.tar.gz)
  • boot filessystem (boot.tar.gz)
  • userdata filesystem (userdata.tar.gz)

Releases of Android LEB and Android Developer Builds are done as part of our monthly Linaro releases and can be consumed from the release wiki page referenced in the Linaro's monthly release announcements.

After downloading the artifacts for your board, you can flash them to your SD card using the linaro-android-media-create tool.

Generating media for your hardware

  1. Download the system, boot and userdata artifacts for the android image you are interested in.
  2. Insert your SD card into the host machine (the machine you downloaded the image and hardware pack).
  3. Ensure you know the device node for your sd card reader. In the following example, we assume/dev/mmcblk0 (you also can use sudo fdisk -l).

  4. In the directory where you downloaded the Android system, boot and userdata tarballs, run linaro-android-media-create $ sudo linaro-android-media-create --dev $BOARD --mmc /dev/mmcblk0 --boot boot.tar.bz2 --system system.tar.bz2 --userdata userdata.tar.bz2  Note: Before you run the linaro-android-media-create, make sure your SD card is an "empty filesystem" card. That means it should not contain any exist filesystem, otherwise, you will get the error messages. For example, you have a SD card, and its filesystem is NTFS, then you run linaro-android-media-create, you will get error messages, even you have deleted all files in this card. One solution for this is you can erase the exist filesystem via "GParted Partition Editor" (you can install it from the ubuntu / Debian repository).

  5. Plug the SD card in your board and boot.

Example: Install Android Panda LEB

Note: In order to install Linaro images you need linaro-image-tools 0.4.8 or greater.

  • Install required packages, download linaro-image-tools and latest released Android Panda LEB.

# install linaro-android-media-create prerequisites  $ sudo apt-get install python-argparse python-parted    # get linaro-image-tools source  $ wget http://launchpad.net/linaro-image-tools/trunk/0.4.8/+download/linaro-image-tools-0.4.8.tar.gz  $ tar xf linaro-image-tools-0.4.8.tar.gz    # get latest android panda-leb artifacts  $ wget http://releases.linaro.org/platform/linaro-n/android/latest/leb-panda/boot.tar.bz2  $ wget http://releases.linaro.org/platform/linaro-n/android/latest/leb-panda/system.tar.bz2  $ wget http://releases.linaro.org/platform/linaro-n/android/latest/leb-panda/userdata.tar.bz2
  • After plugging in your SD card, use dmesg command to figure out the mmc device path:

$ dmesg

and look for something like:

[42335.758962] mmc0: new SDHC card at address e624  [42335.759227] mmcblk0: mmc0:e624 SU04G 3.69 GiB  [42335.759493]  mmcblk0: p1 p2 p3 p4 < p5 p6 >

In this example, the name will be /dev/mmcblk0.

  • Install downloaded release artifacts:

$ sudo /path/to/linaro-android-media-create --mmc /dev/mmcblk0 --dev panda --system system.tar.bz2 --userdata userdata.tar.bz2 --boot boot.tar.bz2

After Installation

Here are few hints of what can be expected and done after the boot:

  1. So far builds come with simplest GUI shell which is not too fancy and doesn't look well on high-res monitor.
  2. You can access shell by running "Dev Tools", and selecting "Terminal Emulator". Google "toolbox" is used as a shell, which lacks tab completion and many basic commands, like grep or more.
  3. There's 0xBench benchmark tool preinstalled.

In Android, you cannot access root console from within the device itself. You can get to it from the host though using one of the following means:

  1. Root console runs on the serial port, so you can access it using serial terminal app like minicom.
  2. Using adb shell from the host. This requires USB gadget mode enabled in the kernel. Not all Linaro releases may have this enabled.
    • Start with typing "getprop ro.secure" in terminal app on the device. You should get "0" for the following steps to work (Linaro builds are configured as such)
    • Go to Settings -> Applications -> Development and ensure that "USB debugging" is set.

    • Use USB A - miniUSB B cable to connect minUSB USB On-The-Go port to a normal port on the host computer. Do NOT ever connect normal USB A sockets on the board and host together - you may damage both irreversibly.
    • In host dmesg, verify that you have some response to the cable insertion. If there're no USB-related images, USB gadget support may be not enabled and following steps won't work.
    • Ensure you have Android SDK installed.
    • Kill any previously running adb process with: adb kill-server

    • Run adb with enough privileges to access USB port: sudo adb devices. You wouldn't need sudo if your udev config is tweaked to allow USB access for normal user, but that's not the case for out-of-box install of Ubuntu (at least 10.10).

    • Run adb shell

  3. If you'd need root access directly on a device, you would need to replace /system/xbin/su with a version which doesn't employ security checks, or install separate tool which would handle the user switch (like sudo). You would need to build those yourself, they are not provided (and such usage is not endorsed) by Linaro.

Board Specific Help

Versatile Express

  • 2012.03 release instructions are here.

Using ADB over TCP/IP

We have a how-to here

https://wiki.linaro.org/Platform/Android/ImageInstallation


 

0 件のコメント:

コメントを投稿