Difference between revisions of "PPC-4407"

From Estone Technology Wiki
Jump to: navigation, search
(Install Dependencies)
(Flashing Image)
 
(21 intermediate revisions by 2 users not shown)
Line 16: Line 16:
  
 
=== Install Dependencies ===
 
=== Install Dependencies ===
 
  
 
* Install required packages on host system.
 
* Install required packages on host system.
<br>
 
 
<code>
 
<code>
$ sudo apt-get update  
+
$ sudo apt-get update
  
$ sudo apt-get install uuid uuid-dev zlib1g-dev liblz-dev liblzo2-2 liblzo2-dev lzop  
+
$ sudo apt-get install uuid uuid-dev zlib1g-dev liblz-dev liblzo2-2 liblzo2-dev lzop
  
$ sudo apt-get install git-core curl u-boot-tools mtd-utils android-tools-fsutils  
+
$ sudo apt-get install git-core curl u-boot-tools mtd-utils android-tools-fsutils
  
 
$ sudo apt-get install openjdk-7-jdk gnupg flex bison gperf libsdl1.2-dev libesd0-dev
 
$ sudo apt-get install openjdk-7-jdk gnupg flex bison gperf libsdl1.2-dev libesd0-dev
Line 35: Line 33:
 
$ sudo apt-get install schedtool g++-multilib lib32z1-dev lib32readline-gplv2-dev gcc-multilib
 
$ sudo apt-get install schedtool g++-multilib lib32z1-dev lib32readline-gplv2-dev gcc-multilib
  
$ sudo apt-get install libswitch-perl gcc-arm-linux-gnueabihf libssl1.0.0 libssl-dev  
+
$ sudo apt-get install libswitch-perl gcc-arm-linux-gnueabihf libssl1.0.0 libssl-dev
 
</code>
 
</code>
  
 
=== Git Configuration ===
 
=== Git Configuration ===
  
 +
* Configure git account <br>
 +
<code>
 +
$ git config --global user.name <B>"First Last"</B>
  
Configure git account: <br>
+
$ git config --global user.email <B>"first.last@company.com"</B>
  
$ git config --global user.name "First Last"
+
$ git config --list
$ git config --global user.email "first.last@company.com"
+
</code>
$ git --list
+
  
 
=== Setting up Repo Utility ===
 
=== Setting up Repo Utility ===
  
 +
* Create repo <br>
 +
<code>
 +
$ cd ~
  
Create repo:
+
$ mkdir ppc4407-android
  
$ cd ~
+
$ cd ppc4407-android
$ mkdir ppc4407-android
+
 
$ cd ppc4407-android
+
$ mkdir bin
$ mkdir bin
+
 
$ curl https://storage.googleapis.com/git-repo-downloads/repo > ~/ppc4407-android/bin/repo
+
$ curl https://storage.googleapis.com/git-repo-downloads/repo > ~/ppc4407-android/bin/repo
$ chmod a+x ~/ppc4407-android/bin/repo
+
 
$ export PATH=${PATH}:~/ppc4407-android/bin
+
$ chmod a+x ~/ppc4407-android/bin/repo
 +
 
 +
$ export PATH=${PATH}:~/ppc4407-android/bin
 +
</code>
  
  
 
=== Download Android Source Code ===
 
=== Download Android Source Code ===
  
Getting Android source code:<br>
+
* Getting Android source code <br>
  
 
Download Android 6.0.1 source code: <br>
 
Download Android 6.0.1 source code: <br>
 +
<code>
 +
$ wget https://www.dropbox.com/s/wtb9y9c3dnxsglz/android-source-imx6-6.0.1-part1.tar.bz2?dl=0
  
$ wget https://www.dropbox.com/s/wtb9y9c3dnxsglz/android-source-imx6-6.0.1-part1.tar.bz2?dl=0
+
$ wget https://www.dropbox.com/s/1lidgac6svw8qeh/android-source-imx6-6.0.1-part2.tar.bz2?dl=0
$ wget https://www.dropbox.com/s/1lidgac6svw8qeh/android-source-imx6-6.0.1-part2.tar.bz2?dl=0
+
$ wget https://www.dropbox.com/s/5ukyd0s8ggrl3xu/android-source-imx6-6.0.1-part3.tar.bz2?dl=0
+
$ cat android-source-imx6-6.0.1-part* > filedir.tar.gz
+
$ tar -xvf filedir.tar.gz
+
  
'''Important:'''
+
$ wget https://www.dropbox.com/s/5ukyd0s8ggrl3xu/android-source-imx6-6.0.1-part3.tar.bz2?dl=0
  
Update all source codes from us for the unit:<br>
+
$ cat android-source-imx6-6.0.1-part* > filedir.tar.gz
  
$ cd android/
+
$ tar -xvf filedir.tar.gz
$ repo init -u https://github.com/estonetechnology/ppc-4407-android-bsp-platform-
+
</code>
$ repo sync
+
 
 +
 
 +
<B>Important:</B> Update all source codes from us for the unit <br>
 +
<code>
 +
$ cd android/
 +
 
 +
$ repo init -u https://github.com/estonetechnology/ppc-4407-android-bsp-platform-
 +
 
 +
$ repo sync
 +
</code>
  
 
== Compiling images ==
 
== Compiling images ==
Setting up build environment: <br>
 
  
 +
<B>Setting up build environment:</B> <br>
 
<code>
 
<code>
 
$ source build/envsetup.sh  
 
$ source build/envsetup.sh  
 
</code>
 
</code>
  
Selecting product to build: <br>
 
  
 +
<B>Selecting product to build:</B> <br>
 
<code>
 
<code>
 
$ lunch sabresd_6dq-user
 
$ lunch sabresd_6dq-user
 
</code>
 
</code>
  
Compiling image: <br>
 
  
 +
<B>Compiling image:</B> <br>
 
<code>
 
<code>
 
$ make  
 
$ make  
 
</code>  
 
</code>  
<br>
 
 
  
 
'''''Note:'''''  If "Make completed successful" appears the compilation is successful
 
'''''Note:'''''  If "Make completed successful" appears the compilation is successful
  
System Files require:
 
  
'''''boot''''' (android/out/target/product/sabresd_6dq)<br>
+
<B>Required Files:</B> <br>
'''''boot-imx6dl''''' (android/out/target/product/sabresd_6dq)<br>
+
'''''boot.img - '''''(android/out/target/product/sabresd_6dq)<br>
'''''boot-imx6q''''' (android/out/target/product/sabresd_6dq)<br>
+
'''''boot-imx6dl.img - '''''(android/out/target/product/sabresd_6dq)<br>
'''''boot-imx6q''''' (android/out/target/product/sabresd_6dq)<br>
+
'''''boot-imx6q.img - '''''(android/out/target/product/sabresd_6dq)<br>
'''''system''''' (android/out/target/product/sabresd_6dq)<br>
+
'''''recovery.img - '''''(android/out/target/product/sabresd_6dq)<br>
'''''u-boot-imx6dl.imx''''' (android/out/target/product/sabresd_6dq)<br>
+
'''''recovery-imx6dl.img - '''''(android/out/target/product/sabresd_6dq)<br>
'''''u-boot-imx6q.imx''''' (android/out/target/product/sabresd_6dq)<br>
+
'''''recovery-imx6q.img - '''''(android/out/target/product/sabresd_6dq)<br>
 +
'''''system.img - '''''(android/out/target/product/sabresd_6dq)<br>
 +
'''''u-boot-imx6dl.imx - '''''(android/out/target/product/sabresd_6dq)<br>
 +
'''''u-boot-imx6q.imx - '''''(android/out/target/product/sabresd_6dq)<br>
  
  
 
+
=== Building Partial Android Image ===
''How to build partial images:''<br>
+
  
 
<B>Building kernel image:</B> <br>
 
<B>Building kernel image:</B> <br>
Line 149: Line 161:
 
<B>Note</B>: Download image and unzip image in your host system <B>(Windows Required)</B>, then follow the instructions in the following section to install on your target system<br>
 
<B>Note</B>: Download image and unzip image in your host system <B>(Windows Required)</B>, then follow the instructions in the following section to install on your target system<br>
  
* [https://www.dropbox.com/s/6rs3yj01b1cww8y/EMB-2230-MNC-10.1-HABEY-20190422-AUOv1.0.zip?dl=0 PPC-4210-10.1-MFG-HABEY-20190422-AUOv1.0.zip]
+
* [https://www.dropbox.com/s/0zrcpozp1d6pcd2/mfg-ppc4407-android-20190902.zip?dl=0 MFG-PPC4407-ANDROID-20190902.zip]
 +
 
 +
<B>Note</B>: To copy the created system files to a directory and overwrite the same file copy to the folder: <br>
 +
<B>mfg-ppc4407-android-20190902\android-mfg\mfgtools\Profiles\Linux\OS Firmware\files\android\sabresd</B>
  
<B>Note</B>:Copy the created system files to a directory(EMB-2230-MNC-10.1-HABEY-20190422-AUOv1.0\mfgtools\Profiles\Linux\OS Firmware\files\android\sabresd)
 
 
== Flashing Image ==
 
== Flashing Image ==
  
* '''Preparation:'''<br>
+
 
Set the boot switch to "2"<br>
+
'''Preparation:'''<br>
 +
 
 +
* Set the boot switch to <B>"2"</B><br>
  
 
[[File:Emb2230-sw2.png|450px]]
 
[[File:Emb2230-sw2.png|450px]]
  
Connect the board to a Windows OS host using OTG cable.<br>
+
 
 +
* Connect the board to a Windows OS host using OTG cable.<br>
  
 
[[File:Emb2230-otg.png|450px]]
 
[[File:Emb2230-otg.png|450px]]
  
Using mfgtools that has been extracted above to flash. Execute the ppc-2230-android.vbs:<br>
+
 
 +
* Using mfgtools that has been extracted above to flash. Execute the <B>ppc-2230-android.vbs</B> script <br>
  
 
[[File:Mfgtool-2.png]]
 
[[File:Mfgtool-2.png]]
 +
 
<br>
 
<br>
Click Start to flash the image.<br>
+
* Click <B>Start</B> to flash the image.<br>
 
[[File:Mfgtool-3.png]]
 
[[File:Mfgtool-3.png]]
 +
 
<br>
 
<br>
The flashing process is done once two processing bars turned to green.<br>
+
* The flashing process is done once two processing bars turned to green.<br>
 
[[File:Mfgtool-4.png]]
 
[[File:Mfgtool-4.png]]
 +
 
<br>
 
<br>
Now, click Stop and Exit the tool.<br>
+
* Once the image is finished flashing click <B>Stop</B> button and Exit the tool.<br>
  
*'''Starting up:'''<br>
+
 
Set the boot switch to "1"<br>
+
'''Starting up:'''<br>
 +
* Set the boot switch to <B>"1"</B><br>
  
 
[[File:Emb2230-sw1.png|450px]]
 
[[File:Emb2230-sw1.png|450px]]
  
Plug in the PoE-Ethernet cable and power on<br>
+
 
 +
* Plug in the PoE-Ethernet cable or regular Power Adapter and power on to boot<br>
  
  
*'''Now, it's running android''' <br>
+
*'''Android image should boot at this point''' <br>

Latest revision as of 22:29, 3 September 2019

Creating Android Image for ppc-4407

Note: The Android Marshmallow 6.0 image was tested on Ubuntu-14.04LTS x64 host system.

Requirements


Minimum Requirements:
CPU - 2 Core Processor
Memory Size - 4GB
Disk Space - 150GB
Operating System - Ubuntu 14.04 LTS

Preparation

Install Dependencies

  • Install required packages on host system.

$ sudo apt-get update

$ sudo apt-get install uuid uuid-dev zlib1g-dev liblz-dev liblzo2-2 liblzo2-dev lzop

$ sudo apt-get install git-core curl u-boot-tools mtd-utils android-tools-fsutils

$ sudo apt-get install openjdk-7-jdk gnupg flex bison gperf libsdl1.2-dev libesd0-dev

$ sudo apt-get install libwxgtk3.0 squashfs-tools build-essential zip libncurses5-dev

$ sudo apt-get install libncurses5-dev schedtool libxml2 libxml2-utils xsltproc libc6-dev

$ sudo apt-get install schedtool g++-multilib lib32z1-dev lib32readline-gplv2-dev gcc-multilib

$ sudo apt-get install libswitch-perl gcc-arm-linux-gnueabihf libssl1.0.0 libssl-dev

Git Configuration

  • Configure git account

$ git config --global user.name "First Last"

$ git config --global user.email "first.last@company.com"

$ git config --list

Setting up Repo Utility

  • Create repo

$ cd ~

$ mkdir ppc4407-android

$ cd ppc4407-android

$ mkdir bin

$ curl https://storage.googleapis.com/git-repo-downloads/repo > ~/ppc4407-android/bin/repo

$ chmod a+x ~/ppc4407-android/bin/repo

$ export PATH=${PATH}:~/ppc4407-android/bin


Download Android Source Code

  • Getting Android source code

Download Android 6.0.1 source code:
$ wget https://www.dropbox.com/s/wtb9y9c3dnxsglz/android-source-imx6-6.0.1-part1.tar.bz2?dl=0

$ wget https://www.dropbox.com/s/1lidgac6svw8qeh/android-source-imx6-6.0.1-part2.tar.bz2?dl=0

$ wget https://www.dropbox.com/s/5ukyd0s8ggrl3xu/android-source-imx6-6.0.1-part3.tar.bz2?dl=0

$ cat android-source-imx6-6.0.1-part* > filedir.tar.gz

$ tar -xvf filedir.tar.gz


Important: Update all source codes from us for the unit
$ cd android/

$ repo init -u https://github.com/estonetechnology/ppc-4407-android-bsp-platform-

$ repo sync

Compiling images

Setting up build environment:
$ source build/envsetup.sh


Selecting product to build:
$ lunch sabresd_6dq-user


Compiling image:
$ make

Note: If "Make completed successful" appears the compilation is successful


Required Files:
boot.img - (android/out/target/product/sabresd_6dq)
boot-imx6dl.img - (android/out/target/product/sabresd_6dq)
boot-imx6q.img - (android/out/target/product/sabresd_6dq)
recovery.img - (android/out/target/product/sabresd_6dq)
recovery-imx6dl.img - (android/out/target/product/sabresd_6dq)
recovery-imx6q.img - (android/out/target/product/sabresd_6dq)
system.img - (android/out/target/product/sabresd_6dq)
u-boot-imx6dl.imx - (android/out/target/product/sabresd_6dq)
u-boot-imx6q.imx - (android/out/target/product/sabresd_6dq)


Building Partial Android Image

Building kernel image:
$ ./build/hb-tools/make.sh k

Building uboot image:
$ ./build/hb-tools/make.sh u

Building boot image:
$ ./build/hb-tools/make.sh b

Building system image:
$ ./build/hb-tools/make.sh a

Building recovery image:
$ ./build/hb-tools/make.sh OTA

Pre-built Android 6 MFG Image

Follow the link below to download mfgtools for the ppc-4407

Note: Download image and unzip image in your host system (Windows Required), then follow the instructions in the following section to install on your target system

Note: To copy the created system files to a directory and overwrite the same file copy to the folder:
mfg-ppc4407-android-20190902\android-mfg\mfgtools\Profiles\Linux\OS Firmware\files\android\sabresd

Flashing Image

Preparation:

  • Set the boot switch to "2"

Emb2230-sw2.png


  • Connect the board to a Windows OS host using OTG cable.

Emb2230-otg.png


  • Using mfgtools that has been extracted above to flash. Execute the ppc-2230-android.vbs script

Mfgtool-2.png


  • Click Start to flash the image.

Mfgtool-3.png


  • The flashing process is done once two processing bars turned to green.

Mfgtool-4.png


  • Once the image is finished flashing click Stop button and Exit the tool.


Starting up:

  • Set the boot switch to "1"

Emb2230-sw1.png


  • Plug in the PoE-Ethernet cable or regular Power Adapter and power on to boot


  • Android image should boot at this point