How to extract kernel config from uImage

Get extract-ikconfig in kernel-source/scripts/ $mkdir extreact-uImage $cd extreact-uImage $cp {kernel-source}/scripts/extract-ikconfig . Dump uImage skip 1024 bytes $cp {uImage/what/you/want} uImage $dd if=uImage of=dd_uImage bs=1024 skip=1 $./extract-ikconfig dd_uImage > config

August 21, 2012 · 1 min · oopsmonk

Build XBMC for Android on lubuntu 12.04

Install required packages # sudo apt-get install build-essential default-jdk git curl autoconf \ unzip zip zlib1g-dev gawk gperf Getting the Android SDK and NDK http://developer.android.com/sdk/index.html SDK : android-sdk_r20.0.1-linux.tgz crystax-5 NDK with enabled support of C++ exceptions, RTTI and Standard C++ Library http://www.crystax.net/en/android/ndk/7#download NDK : android-ndk-r7-crystax-5.beta2-linux-x86.tar.bz2 Installing Android SDK packages <android-sdk> : $HOME/XBMC_Project/android-sdk-linux # cd <android-sdk>/tools # ./android update sdk -u -t platform,platform-tool Setup the Android toolchain <android-ndk> : $HOME/XBMC_Project/android-ndk-r8b <android-toolchain> : $HOME/XBMC_Project/android_toolchain/android-9...

July 28, 2012 · 2 min · oopsmonk

Android Threads, Handlers and AsyncTask

先看過Processes and Threads會有比較清楚的概念, 當Adnroid Application 啟動後, 系統會建一個主要的thread 稱 “main thread” or “UI thread”, 所有的components 皆跑在這個UI thread, system calls 也是透過UI thread dispatched給各個component, ex: onKeyDown, touch event. UI thread 如因大量運算或等待而blocked, 預設超過5秒ANR(Application Not Responding)就會發生. 且Android UI components 並非thread-safe, 使用上要特別小心. 所以: long time computation使用另外的thread, 不要寫在 UI Thread. 不要在UI thread 之外使用UI component method. 透過Thread, Handler and AsyncTask perform asynchronous processing, 避免UI thread block. Threads Android 提供以下的method, 可在其它的thread 下調用 UI thread. Activity.runOnUiThread(Runnable) View.post(Runnable) <-- used in example code....

June 14, 2012 · 1 min · oopsmonk