S3C6410 Board Build Android 2.2

Source: Internet
Author: User

Get ready:
1. Configure the Yum source, uninstall the open JDK, and set the environment variables:
vim/etc/yum.repos.d/centos-base-

[Base]
name=centos-$releasever-base-163.com
baseurl=http://mirrors.163.com/centos/$releasever/os/$basearch/
mirrorlist=http://mirrorlist.centos.org/?release= $releasever &arch= $basearch &repo=os
Gpgcheck=1
Gpgkey=http://mirror.centos.org/centos/rpm-gpg-key-centos-6

#released Updates
[Updates]
name=centos-$releasever-updates-163.com
baseurl=http://mirrors.163.com/centos/$releasever/updates/$basearch/
#mirrorlist =http://mirrorlist.centos.org/?release= $releasever &arch= $basearch &repo=updates
Gpgcheck=1
Gpgkey=http://mirror.centos.org/centos/rpm-gpg-key-centos-6

#additional packages that could be useful
[Extras]
name=centos-$releasever-extras-163.com
baseurl=http://mirrors.163.com/centos/$releasever/extras/$basearch/
#mirrorlist =http://mirrorlist.centos.org/?release= $releasever &arch= $basearch &repo=extras
Gpgcheck=1
Gpgkey=http://mirror.centos.org/centos/rpm-gpg-key-centos-6

#additional packages that extend functionality of existing packages
[Centosplus]
name=centos-$releasever-plus-163.com
baseurl=http://mirrors.163.com/centos/$releasever/centosplus/$basearch/
#mirrorlist =http://mirrorlist.centos.org/?release= $releasever &arch= $basearch &repo=centosplus
Gpgcheck=1
Enabled=0
Gpgkey=http://mirror.centos.org/centos/rpm-gpg-key-centos-6

#contrib-packages by Centos Users
[Contrib]
name=centos-$releasever-contrib-163.com
baseurl=http://mirrors.163.com/centos/$releasever/contrib/$basearch/
#mirrorlist =http://mirrorlist.centos.org/?release= $releasever &arch= $basearch &repo=contrib
Gpgcheck=1
Enabled=0
Gpgkey=http://mirror.centos.org/centos/rpm-gpg-key-centos-6

Yum Clean All
Yum Install test

Uninstalling the Open JDK
Yum Remove *openjdk*
Yum Remove Gcc-java
Installing jdk1.5
Find./*-name *jdk*
RPM-IVH ******jdk1.5.rpm



Setting environment variables

Vim/etc/profile
Join:
Path= $PATH:/usr/local/arm/4.5.1/bin

Export java_home=/usr/java/jdk1.5.0_22
Export JRE_HOME=${JAVA_HOME}/JRE
Export Class_path=.:${java_home}/lib:${jre_home}/lib: $CLASS _path
Export Java_path=${java_home}/bin:${jre_home}/bin
Export Path=${java_path}: $PATH

Vim/etc/bashrc
Join:
Export java_home=/usr/java/jdk1.5.0_22
Export JRE_HOME=${JAVA_HOME}/JRE
Export Class_path=.:${java_home}/lib:${jre_home}/lib: $CLASS _path
Export Java_path=${java_home}/bin:${jre_home}/bin
Export Path=${java_path}: $PATH



2. Software and installation package:
Andorid,teacher_liu


1. Install the Gperf software:
Cd/android/android_patch/tools
Tar xvf gperf-
./configure
Make
Make install

2. Compiling the makefile system
CD Android-2.2_froyo
Make

3. Modify the compiler in the kernel to generate the zimage image
CD android-kernel-2.6.35
Vim Makefile
192gg

ARCH? = Arm
Cross_compile? =/home/hongzhunzhun/hong/android/android/android-2.2_froyo/prebuilt/linux-x86/toolchain/ arm-eabi-4.4.0/bin/arm-eabi-

Make

At the same time as the compilation, to make Bootloader

I. Burning and Writing bootloader
1. Set SD card to start, burn write SD card:
(If you need to find a 2G SD card, format, create a new partition)
Cd/teacher_liu/smdk6410_resource/tools
./write/dev/sdb. /image/u-boot-move.bin
See the light flashing a note on the success of the burning, and then burn not to go in to explain the normal

The board is set to SD card boot, boot.
2. Install minicom, configure minicom
Minicom-s
No no save as de.
3. Install the TFTP and burn the NAND to start up.
Yum Install *tftp/xinted*
Vim Vi/etc/xinetd.d/tftp
Disable = no

Restart TFTP
Service xinted Restart
Cp/android/teacher_liu/smdk6410_resource/images/u-boot-nand.bin
/var/lib/tftpboot/

TFTP NAND u-boot to board in minicom
TFTP 52000000 U-boot-nand.bin
NAND Erase Clean
NAND Write 52000000 0 30000
Set to NAND boot


4. Install the NFS build file system:
Yum Install NFS
Vim/etc/export
/work/android/nfsroot * (Rw,no_root_squash)
Service NFS Restart
Mount-t NFS 192.168.x.x:/work/android/nfsroot/mnt
Umount/mnt

CD Android/android-2.2_froyo/out/target/product/generic
CP root/*/WORK/ANDROID/NFSROOT-RF
CP system//WORK/ANDROID/NFSROOT/SYSTEM-RF
CP data//WORK/ANDROID/NFSROOT/DATA-RF

Cp/android/android/android_patch/init.rc/android/android/android_patch

Vim init.rc
27gg
Comments
setenv Bootargs console=ttysac0 init=/init root=/dev/nfs nfsroot=192.168.1.10:/work/android/nfsroot ip=192.168.1.20
TFTP 50008000 Zimage
Bootm 50008000



Launch simulator
android_product_out= ' pwd ' Emulator-shell



<library name= "Cow"
file= "/system/framework/cow.jar"/>



Three. Write an app to light the LED lights.


1. Directly write an LED bare Board kernel program kernel module


/home/androidproject/android/src/8th_led/ko First look at the files in this directory

LED.C look first, then make put Led.ko to/home/androidproject/android/tftproot/

Then start the board, start well, Insmod Led.ko
Ls/dev/s3c6410_led, you can see the device.




2. Write a kernel module, write an application to perform a switch to control the light

And look at the test.c in the/home/androidproject/android/src/8th_led/exe directory.

And then android-2.2_froyo the directory Mmm/home/androidproject/android/src/8th_led/exe

The test will be generated in the/home/androidproject/android/android-2.2_froyo/out/target/product/generic/system/bin directory
Move the test to the/home/androidproject/android/nfsroot/system/bin/directory

On the board side of the command line to lose./test/dev/led_misc on LED is on
The./test/dev/led_misc off LED is off.




3. Use the app to control the light and off (8th,mmm is compiled in the Android directory

Upper APK Illumination
Process file Jar->apk->so
By the order Mmm,


Copy the raw system directory to Tftproot and restart




In/home/androidproject/android/nfsroot/system/etc/permissions/platform.xml
Add a sentence
<library name= "Cow"
file= "/system/framework/cow.jar"/>




Development Board Insmod Led.ko
chmod 777/dev/led_misc
Give permission
Android will be able to control the lights, lights out

S3C6410 Board Build Android 2.2

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.