Difference between revisions of "PPC-4407"

From Estone Technology Wiki
Jump to: navigation, search
(Flashing Image)
 
(28 intermediate revisions by 2 users not shown)
Line 2: Line 2:
 
= Creating Android Image for ppc-4407 =
 
= Creating Android Image for ppc-4407 =
  
'''''Note:''''' The Android Marshmallow 6.0 was mostly tested in the 14.04 x64 Ubuntu.
+
'''''Note:''''' The Android Marshmallow 6.0 image was tested on Ubuntu-14.04LTS x64 host system.
  
 
== Requirements ==
 
== Requirements ==
  
CPU - '''2 Core Processors'''<br>
+
<br>
 +
<B>Minimum Requirements:</B> <br>
 +
CPU - '''2 Core Processor'''<br>
 
Memory Size - '''4GB '''<br>
 
Memory Size - '''4GB '''<br>
 
Disk Space - '''150GB '''<br>
 
Disk Space - '''150GB '''<br>
Line 13: Line 15:
 
== Preparation ==
 
== Preparation ==
  
Install required packages. Open Terminal and type commands below:
+
=== Install Dependencies ===
<br>
+
$ 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
+
  
Configure git account: <br>
+
* Install required packages on host system.
 +
<code>
 +
$ sudo apt-get update
  
$ git config --global user.name "First Last"
+
$ sudo apt-get install uuid uuid-dev zlib1g-dev liblz-dev liblzo2-2 liblzo2-dev lzop
$ git config --global user.email "first.last@company.com"
+
  
Create repo:
+
$ sudo apt-get install git-core curl u-boot-tools mtd-utils android-tools-fsutils
  
$ cd ~
+
$ sudo apt-get install openjdk-7-jdk gnupg flex bison gperf libsdl1.2-dev libesd0-dev
$ 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
+
  
Getting Android source code:<br>
+
$ sudo apt-get install libwxgtk3.0 squashfs-tools build-essential zip libncurses5-dev
  
Download Android 6.0.1 source code: <br>
+
$ sudo apt-get install libncurses5-dev schedtool libxml2 libxml2-utils xsltproc libc6-dev
  
$ wget https://www.dropbox.com/s/wtb9y9c3dnxsglz/android-source-imx6-6.0.1-part1.tar.bz2?dl=0
+
$ sudo apt-get install schedtool g++-multilib lib32z1-dev lib32readline-gplv2-dev gcc-multilib
$ 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:'''
+
$ sudo apt-get install libswitch-perl gcc-arm-linux-gnueabihf libssl1.0.0 libssl-dev
 +
</code>
  
Update all source codes from us for the unit:<br>
+
=== Git Configuration ===
  
$ cd android/
+
* Configure git account <br>
$ repo init -u https://github.com/estonetechnology/ppc-4407-android-bsp-platform-
+
<code>
$ repo sync
+
$ git config --global user.name <B>"First Last"</B>
  
== Compiling images ==
+
$ git config --global user.email <B>"first.last@company.com"</B>
Setting up build environment:
+
  
$ source build/envsetup.sh
+
$ git config --list
 +
</code>
  
Selecting product to build:
+
=== Setting up Repo Utility ===
  
$ lunch sabresd_6dq-user
+
* Create repo <br>
 +
<code>
 +
$ cd ~
  
Compiling image:
+
$ mkdir ppc4407-android
  
$ make
+
$ cd ppc4407-android
  
'''''Note:'''''  If "Make completed successful" appears the compilation is successful
+
$ mkdir bin
  
System Files require:
+
$ curl https://storage.googleapis.com/git-repo-downloads/repo > ~/ppc4407-android/bin/repo
  
'''''boot''''' (android/out/target/product/sabresd_6dq)<br>
+
$ chmod a+x ~/ppc4407-android/bin/repo
'''''boot-imx6dl''''' (android/out/target/product/sabresd_6dq)<br>
+
'''''boot-imx6q'''''  (android/out/target/product/sabresd_6dq)<br>
+
'''''boot-imx6q''''' (android/out/target/product/sabresd_6dq)<br>
+
'''''system''''' (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>
+
  
 +
$ export PATH=${PATH}:~/ppc4407-android/bin
 +
</code>
  
  
''How to build partial images:''<br>
+
=== Download Android Source Code ===
  
Building kernel image:
+
* Getting Android source code <br>
  
$ ./build/hb-tools/make.sh k
+
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
  
Building uboot image:
+
$ wget https://www.dropbox.com/s/1lidgac6svw8qeh/android-source-imx6-6.0.1-part2.tar.bz2?dl=0
  
$ ./build/hb-tools/make.sh u
+
$ wget https://www.dropbox.com/s/5ukyd0s8ggrl3xu/android-source-imx6-6.0.1-part3.tar.bz2?dl=0
  
Building boot image:
+
$ cat android-source-imx6-6.0.1-part* > filedir.tar.gz
  
$ ./build/hb-tools/make.sh b
+
$ tar -xvf filedir.tar.gz
 +
</code>
  
Building system image:
 
  
$ ./build/hb-tools/make.sh a
+
<B>Important:</B> Update all source codes from us for the unit <br>
 +
<code>
 +
$ cd android/
  
Building recovery image:
+
$ repo init -u https://github.com/estonetechnology/ppc-4407-android-bsp-platform-
  
  $ ./build/hb-tools/make.sh OTA
+
$ repo sync
 +
</code>
 +
 
 +
== Compiling images ==
 +
 
 +
<B>Setting up build environment:</B> <br>
 +
<code>
 +
$ source build/envsetup.sh
 +
</code>
 +
 
 +
 
 +
<B>Selecting product to build:</B> <br>
 +
<code>
 +
$ lunch sabresd_6dq-user
 +
</code>
 +
 
 +
 
 +
<B>Compiling image:</B> <br>
 +
<code>
 +
$ make
 +
</code>
 +
 
 +
'''''Note:''''' If "Make completed successful" appears the compilation is successful
 +
 
 +
 
 +
<B>Required Files:</B> <br>
 +
'''''boot.img - '''''(android/out/target/product/sabresd_6dq)<br>
 +
'''''boot-imx6dl.img - '''''(android/out/target/product/sabresd_6dq)<br>
 +
'''''boot-imx6q.img - '''''(android/out/target/product/sabresd_6dq)<br>
 +
'''''recovery.img - '''''(android/out/target/product/sabresd_6dq)<br>
 +
'''''recovery-imx6dl.img - '''''(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 ===
 +
 
 +
<B>Building kernel image:</B> <br>
 +
<code>
 +
$ ./build/hb-tools/make.sh k
 +
</code>
 +
 
 +
<B>Building uboot image:</B> <br>
 +
<code>
 +
$ ./build/hb-tools/make.sh u
 +
</code>
 +
 
 +
<B>Building boot image:</B> <br>
 +
<code>
 +
$ ./build/hb-tools/make.sh b
 +
</code>
 +
 
 +
<B>Building system image:</B> <br>
 +
<code>
 +
$ ./build/hb-tools/make.sh a
 +
</code>
 +
 
 +
<B>Building recovery image:</B> <br>
 +
<code>
 +
$ ./build/hb-tools/make.sh OTA
 +
</code>
  
 
== Pre-built Android 6 MFG Image ==
 
== Pre-built Android 6 MFG Image ==
Line 112: 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>
 
  
[[File:Emb2230-rj45.png|450px]]
+
* 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