IoTGateway/BSP/Android/User Guide 10.0.0 For i.MX8

Revision as of 04:12, 16 July 2021 by Wei.zeng (talk | contribs) (Created page with "= = == Contents == hide  *[")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search



Android BSP Version[edit]

Android 10.0.0_r35


This document describes how to work with the RISC and ELAA Android 10.0.0 Board Support Package (BSP) release. The BSP includes bootloaders; the Android Linux kernel and root file system; and tools and documentation to ease the development, deployment, and execution of Android-based systems.

Setup Ubuntu Host Computer[edit]

Required equipment and software[edit]

  • Ubuntu 18.04 LTS 64bit for Android build host OS
  • 130G bytes free disk spaces for build image

Install Ubuntu[edit]

  • IMPORTANT! You must be able to log in as root or use sudo to have root permissions during the installation.

Go to [1] and download 64-bit PC (AMD64) desktop image: [2] for the installation.

Run Docker example[edit]

Step1 Run docker container (example)

 $ docker run -it --name android_q10 -v /home/bsp/myandroid:/home/adv/BSP:rw advrisc/u18.04-rk3399abv10 /bin/bash

Step2 In container, change the user. (example)

 adv@7cc0fa834366:~$ sudo chown adv:adv -R BSP

Install docker and Use docker[edit]

Please use docker environment to compiler Android 10.0.0

  • Android 10.0.0 Docker
  • Image Repository : advrisc/u18.04-rk3399abv10
  • Image Tag : lastest

Reference: [3]

To pull Docker image from Docker Hub[edit]

  • docker pull advrisc/advrisc/u18.04-rk3399abv10
  • docker run --name imx8ABV10 -it advrisc/u18.04-rk3399abv10 /bin/bash

Getting Android Source Code[edit]

Related version information:[edit]

  • Android 10.0.0_r35
  • kernel Yocto-3.0
  • U-Boot Yocto-3.0

Step1 : To pull down the Android source tree to your working directory from the repositories as specified in the default manifest

$ git config --global "Your Name" 
$ git config --global
$ mkdir myandroid

$ mkdir bin

$ cd myandroid/ $ curl > ../bin/repo

$ chmod a+x ../bin/repo $ ../bin/repo init -u -b q10.0.0_2.3.0-ga release_version.xml

$ ../bin/repo sync

=== The release_version.xml  as follows:
ROM3720 for adv_android-10.0.0_2.3.0.xml

Step2: Patch to Android Q10.0.0.0

$ cd ~/myandroid/vendor/nxp-opensource/uboot-imx/

$ patch -p1 < ../../../patches_android-10.0.0_r35/10001-Linux_Yocto_5.4.24_2.1.0-to-android-10.0.0_r35.patch

$ cd ~/myandroid/vendor/nxp-opensource/kernel_imx/

$ patch -p1 < ../../../patches_android-10.0.0_r35/10001-Uboot_Yocto_5.4.24_2.1.0-to-android-10.0.0_r35.patch

$ cd myandroid

Building Android 9.0.0 image for SD card[edit]

If your product is ROM-3720, the product name is rom3720_a1

$PRODUCT = rsb3720_a1

Build Instructions[edit]

Set the $JAVA_HOME environment variable

$ export JAVA_HOME=/usr/lib/jvm/java-8-openjdk-amd64/

Set up the environment for building. This only configures the current terminal.

$ source build/

Execute the Android lunch command. In this example, the setup is for the production image of Advantech RISC platfrom device with user type. If you devices is ROM3720, you will be send command rom3720_a1-userdebug

$ lunch $PRODUCT-userdebug

To build boot loader

Perform the following command in terminal console

$ ./ bootloader -j8

The two files, u-boot_crc.bin & u-boot_crc.bin.crc, will be located in directory, ./out/target/product/product_name

To build boot image

Perform the following command in terminal console

$ make bootimage -j8

To build dtbo image (kernel device tree)

Perform the following command in terminal console

$ make dtboimage -j8

To build system image

Perform the following command in terminal console

$ make -j8

Burning image[edit]

SD card boot[edit]

Go to those built image file directory

For daily build

$ cd ~/image/

For local build

$ cd ~/out/target/product/PRODUCT_NAME/

Enter flash command

For ROM-3720

$ sudo ./ -super -f imx8mp /dev/sdX (X : SD card device drive)