Build the basic ROM
Unfortunately the information related to our ROM and SDK are still available only in Chinese, that's why with this project on XDA we are willing to make a translation of all the necessary resources needed to develop for OXY.
In this specific post I am going through the creation of a development environment using
Ubuntu 12 LT which in my case is hosted on
Windows Azure Asia Servers so that the download from GIT is faster and more reliable. At the end you will have the basic IWOP image built. IWOP is a the custom Android ROM built by Ingenic which runs on our Hardware.
If you are considering to join the Development Program in OXY or if you are considering to become a remunerated Developer for OXY, we will grant you an Ubuntu VM with the development environment ready to go and an OXY SmartWatch development kit, in order to be able to test your code on our hardware.
Resource location
The resources are available at the website of Ingenic, the official page which is visible from outside China and supported also by OXY also:
http://iwop.ingenic.com/zh-cn/. We are actively working on translating the website in English-US so that in the future the IWOP SDK will be available in full English.
First step you need to download the
REPO TOOL and the GIT structure. To make this job easier we have created a custom folder containing the entire repo which is available on Google Drive. We have also the full source code (~25GB) available for download in case you cannot download from our Chinese mirror.
In order to avoid unfriendly behaviors from competitors and in order to avoid to run out of bandwidth, the Google Drive is shared only with the active members of the OXY Development Program, just drop me a PVT if you are willing to join the project.
Once the REPO structure is downloaded and unzipped, you will end up with the following folder of almost 5GB in size:
Now you are ready to compile
ELF. ELF is a custom version of Android built by Ingenic to work on their CPU architecture and on their hardware. The ROM is quite stable and it has already a rich set of API available through their SDK to work directly on OXY SmartWatches and in the future with OXY SmartPhones.
Now run a sync with the local repository:
Code:
$ .repo/repo/repo sync --local-only
Second step, in order to download the full-source you need an SSH account from us.
Again, in order to avoid problems of bandwidth at this stage of the project we will grant SSH files and accounts only to users that are joining the dev program
Then you can run a sync against the Ingenic GIT repository and download the entire source code:
Code:
$ .repo/repo/repo init -u ssh://[account]@oxytechs.com:29418/elf/manifests.git -b release-4.3 -m elf.xml
And synchronize
Code:
$ .repo/repo/repo sync --current-branch --no-tags
Beware that if your machine is not in ASIA the first synchronization is very slow, the full source is between 20~24GB
Configure the Development Machine
In these steps we are using Eclipse to build our ROM, feel free to switch to Android Studio and if you have achieved the migration to Android Studio, feel free also to update this guide
Install the SDK 1.6
The correct SDK for ELF is available at this address:
http://www.oracle.com/technetwork/java/javase/downloads/jdk6-downloads-1637591.html
Then you have to register the SDK in your PATH using:
Code:
export JAVA_HOME=/work/soft/jdk1.6.0_33
export PATH=$PATH:$JAVA_HOME/bin
Finally you can verify that the SDK is correctly installed by typing:
Code:
$java -version
java version "1.6.0_33"
Java(TM) SE Runtime Environment (build 1.6.0_33-b04)
Java HotSpot(TM) 64-Bit Server VM (build 20.8-b03, mixed mode)
Download the ELF SDK available on our Google Drive
Then register the SDK on your environment:
Code:
export ANDROID_HOME=~/work/soft/android-sdk-linux
export PATH=$PATH:$ANDROID_HOME/tools
export PATH=$PATH:$ANDROID_HOME/platform-tools
export PATH=$PATH:$ANDROID_HOME/build-tools
Download the Linux NDK available on our Google Drive
Then register the NDK:
Code:
export NDK_HOME=~/work/soft/android-ndk-r10
export PATH=$PATH:$NDK_HOME
Prepare Ubuntu for Build Android
If you machine is new and you never built Android SDK before, you need to install also these packages in the correct order and
Do not upgrade these packages
Code:
$ sudo apt-get install git-core gnupg flex bison gperf build-essential \
zip curl libc6-dev libncurses5-dev:i386 x11proto-core-dev \
libx11-dev:i386 libreadline6-dev:i386 libgl1-mesa-glx:i386 \
libgl1-mesa-dev g++-multilib mingw32 openjdk-6-jdk tofrodos \
python-markdown libxml2-utils xsltproc zlib1g-dev:i386
$ sudo ln -s /usr/lib/i386-linux-gnu/mesa/libGL.so.1 /usr/lib/i386-linux-gnu/libGL.so
Build
Finally you can build ELF for OXY using the following commands:
SQUARE
Code:
./build/smk.sh --preset=aw808_v11_wisesquare_iwop
ROUND
Code:
./build/smk.sh --preset=aw808_v11_naturalround_iwop
You will end up with the following files which are the ELF ROM for OXY.
u-boot-with-spl-mbr-gpt.bin、 boot.img、 system.img、 recovery.img
Now you are ready to: customize the ROM, customize the Home launcher, create new apps for OXY
In the next post we will write the basics of how to create an Android App for OXY SmartWatch and how to upload the app on our Cloud using REST