Dual Android 2.2


The below tutorial outlines how to run two instances of virtualized Androids on TI OMAP4 dual core Cortex-A9 panda board, using the pre-built binaries.

Demonstration details

  • The following demo is for RevC release of panda boards, having OMAP 4430 processors.
  • We will run two instances of virtualized Android kernels, parallely, over the Codezero hypervisor.
  • Android#0 will boot using the filesystem present on a USB stick while Android#1 will boot using the filesystem present on the SD card.
  • Android kernels as well as filesystems are based on L_27.8 pandroid, based on 2.2 Froyo Android, release by Texas Instruments.
  • Android#0 will boot on Core0 and Android#1 will boot on core1.

Hardware requirements

  • RevC panda board.
  • USB 2.0 compliant flash drive with a minimum of 4GB storage.
  • 4GB SDHC memory card.
  • HDMI display.
  • USB mouse/keyboard, preferably a wireless USB dongle over which both keyboard and mouse can work together, since we use the other available USB port for storing Android#0 filesystem.
  • Serial to USB converter.

Downloading the pre-built binaries

Download binaries from here. It contains the following files

  • MLO – X-Loader
  • u-boot.bin – U-boot
  • final.elf – ELF file containing Codezero, Android#0 and Android#1 kernels
  • android0.tar.gz – Android#0 filesystem tarball
  • android1.tar.gz – Android#1 filesystem tarball
  • panda-formatsd.sh – Script to format SD card

Setting up the demo

Format the USB drive using EXT3 filesystem. You can use either fdisk or gparted for this.

Extract Android#0 filesystem on USB drive

$ cd <sdcard-ext3 partition>
$ sudo tar -xvf android0.tar.gz
$ sudo mv afs/* .

Format the SD card using

$ sudo panda-formatsd.sh /dev/sdX; where sdX is the block device corresponding to the SD card.

This will create a FAT partition named boot, and an EXT3 partition named rootfs on the SD card.

Eject and re-plug the card on the host.

Copy MLO, u-boot.bin, and final.elf files in boot partition of the SD card.

Extract the Android#1 filesystem in rootfs partition of the SD card.

$ cd rootfs
$ sudo tar -xvf android1.tar.gz
$ sudo mv minimal-android/* .

Plug the USB flash drive, SD card, HDMI display and USB keyboard/mouse to the panda board.

Connect the serial port of panda board to the host using serial to usb converter. And attach minicom to the serial converter device to get the panda boot logs and serial console

$ minicom -D /dev/ttyUSBn; here /dev/ttyUSBn is the usb to serial converter device.

Configure Minicom’s serial port for following settings

Baud Rate: 115200n8
Hardware flow control: OFF
Software flow control: OFF

Power on the board.

Successful setup should result in Android#0 GUI appearing on HDMI screen and Android#1′s shell should appear on Minicom.

Switching GUI between Android#0 and Android#1

Initially Android#0 appears over the HDMI screen. To switch to Android#1′s GUI, we need to connect to Android#1′s VNC server; To do the same

Click on the AndroidVNC application
Enter the following connection details IP-Address:, Port: 5901, Colours/Bits per Pixel: 24(4bit)
Press Connect

This should reveal the second full blown Android instance on HDMI.

Known issues

  • First boot from the USB stick may take sometime. This limitation imposed by storage device speed.
  • Android#1 VNC screen may be a bit slower if used with high resolution settings. This limitation is imposed by the VNC client-server setup.

Replacing Android#1 with Linux

To boot Linux based distribution instead of Android#1 follow exactly the same procedure as mentioned above, but instead of using android1.tar.gz use buildroot based linux distro from here.

Extract the Linux filesystem/distro in rootfs partition of the SD card.

$ cd rootfs
$ sudo tar -xvf linux-vx-rootfs.tar.gz
$ sudo mv rootfs/* .
$ sudo chown 1000:1000 .
$ sudo chown 1000:1000 ./* -R

Also, to connect to the VNC server of Linux from Android#0 VNC client use the following settings

IP-Address:, Port: 5900, Colours/Bits per Pixel: 24(4bit)

Other than this, all the procedure is same as mentioned in Setting up the demo section above.

Once you are connected to the VNC server of Linux, if Linux screen shows black area in background i.e whole screen is not used by Linux, fix the screen geometry in rootfs/etc/init.d/S32vnc; here pass the correct geometry to Xtightvnc based on your display resolution. Fix this and reboot.

Building from sources

Check the Building from Source for Panda page for instructions on building Codezero and Android kernels from the sources.



Comments are closed.