Android Based Optimus One Anatomy

Android Based Optimus One Anatomy

www.kandroid.org Kandroid community’s minimal seminar Android based Optimus One Anatomy ( Ver 1.0 ) Jan-29-2011 Geunsik Lim (Nick:인베인, leemgs.at.gmail.com) Jeongsoo Yang (Nick:들풀, yangjeongsoo.at.gmail.com) * Case study: KU3700/LU3700/SU370 Optimus One = Optimus S (Sprint) = Optimus T (T-Mobile) = Optimus Vortex (Verizon) = Optimus Chic ü * 본 문서는 비상업적 용도에 한해서 자유롭게 수정 및 재배포 가능합니다. 단, 이 경우 그 출처를 명시해야 합니다. CONTENTS Android Technology Session 1. OptimusOne Spec 2. Host Linux Environments 3. License Issues of OptimusOne 4. CPU & Memory Information 5. OptimusOne’s BSP Source Summary 6. Build Android Full source for OptimusOne 7. Build Android Kernel source for OptimusOne 8. Fastboot to update the flash filesystem 9. Make custom image for performance directly 10. Kernel internals of OptimusOne 11. Appendix. OptimusOne’s Update Flowchart How to Solve Some Problems After Purchase LG Optimus One Specs 1. Software Google Android 2.2 (Froyo) 2. Chipset CPU: Texas Instruments OMAP 3630 (ARMV6 Cortex-A8) Clock Speed: 600Mhz 3. Display Display Type: color transflective TFT , 262144 scales Display-Diagonal: 3.2 " Display_Resolution: 320 x 480 4. Cellular Phone Cellular-Networks: CDMA800, CDMA1900 Call Alert: 72 -chord melody 5. Etc Positioning:Device: Multi-touch screen Expansion-Slots: microSD, microSDHC, TransFlash USB: USB 2.0 client, 480Mbit/s(MAX), micro-USB Bluetooth: Supported Wireless+LAN: 802.11b, 802.11g Complementary: Assisted GPS, QuickGPS, Geotagging Main_Camera: 3.1 MP Battery+Capacity: 1500 mAh Korea Android Mini Seminar 3/43 Environment of Host Linux * Linux Distribution: Fedora 11 - http://ftp.neowiz.com/pub/fedora/releases/11/Fedora/i386/iso/Fedora-11-i386-DVD.iso * Linux Kernel: Linux 2.6.29.6-217.2.3.fc11.i686.PAE #1 SMP * GCC Compiler: gcc 3.4.6 20060404 (Red Hat 3.4.6-13) gcc 4.4.1 20090801 (Red Hat 4.4.1-2) * JAVA Virtual Machine - Java(TM) 2 Runtime Environment Standard Edition (build 1.5.0_22-b03) - http://java.sun.com/javase/downloads/previous.jsp Korea Android Mini Seminar 4/43 Process(Thread) and Memory Information ●system_server 67 * Total Numbers: 612 ●m.android.phone 32 * Kernel Threads: 46 ● e.process.gapps 29Quiz * U/S Processes : 79 ●ogle.android.gm 23 Quiz ● * U/S Threads: 487 com.kakao.talk 22 ●d.process.acore 21 MemTotal: 427556 kB Dirty: 24 kB MemFree: 10060 kB Writeback: 0 kB Buffers: 4028 kB AnonPages: 245376 kB Cached: 133004 kB Mapped: 53952 kB SwapCached: 0 kB Shmem: 1080 kB Active: 185308 kB Slab: 11440 kB Inactive: 194332 kB SReclaimable: 3448 kB Active(anon): 121880 kB SUnreclaim: 7992 kB Inactive(anon): 124568 kB KernelStack: 4520 kB Active(file): 63428 kB PageTables: 16404 kB Inactive(file): 69764 kB NFS_Unstable: 0 kB Unevictable: 2760 kB Bounce: 0 kB Mlocked: 0 kB WritebackTmp: 0 kB SwapTotal: 0 kB CommitLimit: 213776 kB SwapFree: 0 kB Committed_AS: 6075776 kB VmallocTotal: 303104 kB VmallocUsed: 87112 kB VmallocChunk: 182276 kB Korea Android Mini Seminar 5/43 I/O Memory Information 12800000-2fefffff : System RAM (493,879,295bytes) 1282d000-12deafff : Kernel text (6,021,119 bytes) 12e10000-130785ef : Kernel data (2,524,655 bytess) 1611c000-1631bfff : kgsl_phys_memory 2ff00000-2ff3ffff : ram_console 98000000-9800ffff : dmb_ebi2_phys_memory a0000000-a001ffff : kgsl_reg_memory a0000000-a001ffff : kgsl a0200000-a0200fff : msm_serial_hs.0 a0400000-a0400fff : msm_sdcc.1 a0500000-a0500fff : msm_sdcc.2 a0800000-a08003ff : msm_hsusb a0800000-a08003ff : msm_otg a0a00000-a0a007ff : msm_nand_phys a0d00000-a0d000ff : dmb_ebi2_cr_base a0d10000-a0d100ff : dmb_ebi2_xm_base a9900000-a9900fff : msm_i2c.0 a9900000-a9900fff : msm_i2c aa200000-aa2effff : mdp aa600000-aa600fff : pmdh Korea Android Mini Seminar 6/43 Open-source License Technical Issues * What are GPL licenses that used on OptimusOne model ? - Linux, DBUS, BLUETOOTH, ALSA , and so on libdbus.so GPL Message Bus System Library lib-bluetooth.so GPL Bluetooth library (bluez-plugin ) libalsa.so(libsnd.so) GPL Advanced Linux Sound Architecture (ALSA) wireless.ko GPL kernel module for broadcom wireless device driver Linux Kernel GPL Kernel source by Linus Tovalds * Official Notice for providing source code (Setting Menu) LG Electronics offers to provide source code to you on CD-ROM for a charge covering the cost of performing such distribution, such as the cost of media, shipping and handling upon e-mail request to LG Electronics at [email protected] This offer is valid for a period of three years from the date of the distribution of the product by LG Electronics. (http://opensource.lge.com) Korea Android Mini Seminar 7/43 Open-source License Legal Issues Android 기반 모바일 폰의 Android 2.2소스를 정상 빌드 후에 빌드된 이미지 (예: zImage(Kernel) , ramdisk.img , system.img, userdata.img)를 Android Phone에 탑재하기 위해 판매회사의 담당자에게 해당 지침서 또는 가이드를 요청. SFLC( Software Freedom Law Center; www.softwarefreedom.org )의 권고 준수사항에 의하면, 오픈소스 제공의무의 범위는 “GPL관련 소스들의 컴파일 결과물을 제품에 탑재하는 것에 대한 가이드 까지 제공해야 하는 것”을 의무조항으로 하고 있다. SFLC 기관에서 소스코드의 제공 범위에 대해서 아래와 같이 해석하고 있다. • GPLV2/V3(Original Code) -> 생산/배포자 -> GPLV2/V3 based S/W release -> Open sources [ (1) Related source code + (2) Items “needed to generate + (3) install & run” the GPL’d programs ] -> End User(Customers) 해당 라이센스의 준수사항에 대해 질의 내용 및 요구사항들이 있다면, www.softwarefreedom.org 및 gpl-violation.org에 해당 사항에 대해 논의가 가능하다. 라인센스 조항 미 준수사항이 밝혀지게 되는 경우 관련 회사는 브랜드 이미지 실추 및 클레임에 대한 제바 비용을 감당해야 한다. 또한, 자유 소프트웨어 해커들로부터 전반적인 제품에 대한 보다 적극적인 위반여부를 감시받을 수 있다. Korea Android Mini Seminar 8/43 Android Applications for H/W Benchmark Subset of aroung 400 OpenGL ES 2.0 tests *J android hacker's system * DEQP-Mini: the quality of the * Quadrant Standard Edition graphics support(OpenGL ES 2.0 tool : CPU Frequency Moni- (CPU, Memory, I/O, benchamrk) in your device toring 2D/3D graphics) Korea Android Mini Seminar 9/43 Necessary packages in Host Linux PC geunsik@f11#> geunsik@f11#> geunsik@f11#> sudo yum install git-core gnupg sun-java5-jdk \ flex bison gperf libsdl-dev libesd0-dev libwxgtk2.6-dev \ build-essential zip curl libncurses5-dev zlib1g-dev valgrind libpng libpng-dev Korea Android Mini Seminar 10/43 Installation GCC & JAVA to build android full source geunsik@f11#> geunsik@f11#> yum install compat-gcc* geunsik@f11#> rpm -qa | grep compat-gcc compat-gcc-34-3.4.6-9.i386 compat-gcc-34-c++-3.4.6-9.i386 compat-gcc-34-g77-3.4.6-9.i386 geunsik@f11#> geunsik@f11#> vi /etc/profile # http://java.sun.com/javase/downloads/previous.jsp export JAVA_HOME=/usr/lib/jvm/jdk1.5.0_22 export PATH=.:$JAVA_HOME/bin:$JAVA_HOME/jre/bin:/home/invain/bin:$PATH export ANDROID_JAVA_HOME=$JAVA_HOME geunsik@f11#> geunsik@f11#> source /etc/profile Korea Android Mini Seminar 11/43 Download Android Full source from official web- site geunsik@f11#> cd /opt/mydroid-froyo geunsik@f11#> wget http://android.git.kernel.org/repo geunsik@f11#> chmod 755 repo geunsik@f11#> repo init -u \ git://android.git.kernel.org/platform/manifest.git -b froyo geunsik@f11#> time repo sync Korea Android Mini Seminar 12/43 Download OptimusOne BSP source from LGE * Contacts : “OpenSource” <[email protected]> “OpensourceMC” <[email protected]> * Official URL: http://opensource.lge.com - Mobile Phone - “KU3700” * BSP files : KU3700_Android_Froyo_OpenSource.zip (99MB) 1) LG-KU3700_kernel.tar.gz (65MB) 2) LG-KU3700_android.tar.gz (34MB) 61.0MB ./dalvik 95.0MB ./external 13.0MB ./hardware 01.9MB ./vendor Korea Android Mini Seminar 13/43 Sub-directories information geunsik@f11#> du -sh ./OptimusOne_OpenSource_V2.2-20101105 4.0K ./Makefile 13M ./bionic 4.2M ./bootable 4.1M ./build 74M ./cts 97M ./dalvik 39M ./development 9.6M ./device 750M./external 303M./frameworks 37M ./hardware 374M./kernel 61M ./ndk 3.9G ./out 98M ./packages 945M./prebuilt 14M ./sdk 26M ./system 1.9M ./vendor Korea Android Mini Seminar 14/43 Merge BSP into Android 2.2 Generic source geunsik@f11#> cd /opt/mydroid-froyo geunsik@f11#> cp -arf /opt/KU3700/ku3700_opensource_android/* /opt/mydroid-froyo/ geunsik@f11#> cd /opt/mydroid-froyo geunsik@f11#> cp -arf /opt/KU3700/kernel /opt/mydroid-froyo/ Korea Android Mini Seminar 15/43 Build Kernel Source (Linux 2.6.32 base) 1/2 geunsik@f11#> cd /opt/mydroid-froyo/kernel geunsik@f11#> cp -arf ../prebuilt/linux-x86/toolchain/arm-eabi-4.2.1 /usr/local/ geunsik@f11#> vi /etc/profile # Crosscompiler env setting for OptimusOne 2.2(Froyo) export PATH=$PATH:/usr/local/arm-eabi-4.2.1/bin/ geunsik@f11#> make ku3700-perf_defconfig geunsik@f11#> ls -al ./arch/arm/boot/ - zImage(3.0MB ; Image 6.7MB) file will be located in ./arch/arm/boot/ directory. * “ku3700-perf_defconfig” 환경파일의 주요 구성 내용 . CPU : Qualcom MSM7X27 (ARM V6 32Bit ARM1136jf-S @600Mhz) . ARM THUMB Support . ARM TLB V6 . Preemptible Mode (Preemption Mode) . OABI Compatibile Mode . Command Mode: init=/sbin/init root=/dev/ram rw initrd=0x11000000,16M console=ttyDCC0 mem=88M Korea Android Mini Seminar 16/43 Build Kernel Source (Linux 2.6.32 base) 2/2 geunsik@f11#> make -j 4 ; make modules ; geunsik@f11#> sudo make modules_install geunsik@f11#> tree /lib/modules/2.6.32.9/kernel/ *arch/arm/mach-msm/dma_test.ko *arch/arm/mach-msm/reset_modem.ko *crypto/ansi_cprng.ko *drivers/input/evbug.ko *drivers/input/lgosp-hid/lgosp-hid.ko *drivers/misc/pmem_kernel_test.ko *drivers/mtd/tests/mtd_oobtest.ko *drivers/mtd/tests/mtd_pagetest.ko *drivers/mtd/tests/mtd_readtest.ko *drivers/mtd/tests/mtd_speedtest.ko *drivers/mtd/tests/mtd_stresstest.ko *drivers/mtd/tests/mtd_subpagetest.ko *drivers/mtd/tests/mtd_torturetest.ko *drivers/net/wireless/bcm4325/wireless.ko *drivers/net/wireless/libra/librasdioif.ko *drivers/scsi/scsi_wait_scan.ko Korea Android Mini Seminar 17/43 Can You customize

View Full Text

Details

  • File Type
    pdf
  • Upload Time
    -
  • Content Languages
    English
  • Upload User
    Anonymous/Not logged-in
  • File Pages
    43 Page
  • File Size
    -

Download

Channel Download Status
Express Download Enable

Copyright

We respect the copyrights and intellectual property rights of all users. All uploaded documents are either original works of the uploader or authorized works of the rightful owners.

  • Not to be reproduced or distributed without explicit permission.
  • Not used for commercial purposes outside of approved use cases.
  • Not used to infringe on the rights of the original creators.
  • If you believe any content infringes your copyright, please contact us immediately.

Support

For help with questions, suggestions, or problems, please contact us