發表文章

目前顯示的是有「android develop」標籤的文章

Bitmap OOM & MAT

Bitmap OOM & MAT 如何改善Bitmap所帶來的Out of Memory(OOM)問題 解決在 Android 中使用 Bitmap 造成 Out of memory 的方法~ [Android]Android Out Of Memory(OOM) 的詳細研究 HOWTO: Debug Memory Leak in Android

關於AOSP Contacts討論

關於AOSP Contacts討論 source code : https://android.googlesource.com/platform/packages/apps/Contacts Working with Contacts 翻譯 -  討論Android 2.0 Contacts的變化 ... 不過現在已經Android 4.0了 XD 更多小技巧: Android-通過PhoneLookup讀取所有電話號碼 Android獲取手機相關資訊和SIM卡資訊 自動搜尋 AutoCompleteTextView ~ 搭配Contacts 撈出聯絡人資料 ~ 照片 ContactsContract.Contacts.PHOTO_ID

how to install FindBugs

how to install FindBugs In Eclipse, click on  Help  ->  Software Update  -> Find and Install... Choose the  Search for new features to install  option, and click  Next . Click  New Remote Site . Enter the following: Name:  FindBugs update site URL:  one of the following (note: no final slash on the url) http://findbugs.cs.umd.edu/eclipse  for official releases http://findbugs.cs.umd.edu/eclipse-candidate  for candidate releases and official releases http://findbugs.cs.umd.edu/eclipse-daily  for all releases, including developmental ones and click  OK .

關於Audio開發需要了解的事情

關於Audio開發需要了解的事情 Data Formats (or Audio Encoding) File Formats (or Audio Containers) Bit Rates Sample Rates 本來想要找一下Android跟iOS的 Audio開發相關文章做比較,才發現Android 跟iOS跟官方教學網站真是不能比。 Android Android Supported Media Formats Multimedia and Camera : Media Playback Multimedia and Camera : Audio Capture iOS Audio & Video Starting Point Multimedia Programming Guide - Using Audio 2010 Audio 101 for iPhone Developers: File and Data Formats 2010 Sound on iOS: Best Practices

How to trace ANR

How to trace ANR problem ! What Triggers ANR? http://developer.android.com/guide/practices/design/responsiveness.html In Android, application responsiveness is monitored by the Activity Manager and Window Manager system services. Android will display the ANR dialog for a particular application when it detects one of the following conditions: No response to an input event (e.g. key press, screen touch) within 5 seconds A  BroadcastReceiver  hasn't finished executing within 10 seconds How to investigate an ANR  http://stackoverflow.com/questions/704311/android-how-do-i-investigate-an-anr An ANR happens when some long operation takes place in the "main" thread. This is the event loop thread, and if it is busy, Android cannot process any further GUI events in the application, and thus throws up an ANR dialog. Now, in the trace you posted, the main thread seems to be doing fine, there is no problem. It is idling in the MessageQueue, waiting for another message to come in. ...

Could not create the Java Virtual Machine.

如果在Android 遇到 Could not create the Java Virtual Machine. anan A fatal exception has occurred. Program will exit. [dx] Error occurred during initialization of VM [dx] Could not reserve enough space for object heap  default SDK  那就到 android-sdks\platform-tools 目錄中的 dx.bat 檔案, 將 set defaultXmx=-Xmx1024M 改為 set   defaultXmx=-Xmx512M 若是自己Build AOSP 在source code裡  修改 /dalvik/dx/etc/dx.bat 將 set defaultXmx=-Xmx1024M 改為 set   defaultXmx=-Xmx512M

江湖一點訣 Android Handler Thread

江湖一點訣 Android Handler Thread  Android Tips 開發小技巧 - Handler.post Android Tips 開發小技巧 - Thread 無法 Interrupted!? Android Tips 開發小技巧 - Activity.runOnUiThread

How to submit patch to Android Open Source Project

Life of a Patch Submitting Patches   http://source.android.com/source/submit-patches.html Open的 Gerrit  https://android-review.googlesource.com/#/q/status:open,n,z

Android裝置開發名詞整理

圖片
除了 通訊類名詞 外,工作上還有很多名詞 ...  一個Android裝置包含了 App、Android framework、RIL 、 Protocol  BSP、 Modem 、HW。 整理工作中遇到的名詞們,快速查詢。 Android BT profile BSP Board Support Package Cupcake Cross Compiler  CDD Compatibility Definition Document CS Commercial Software CTS Compatibility Test Suite Donut DRM  ( Digital Rights Management) Eclair EFS  ( Encrypting File System ) Froyo Framebuffer GDB  ( GNU Debugger ) Gingerbread  GPIO  ( General Purpose Input/Output. ) GZIP Honeycomb JSON ICS i2c  ( Inter - Integrated Circuit )  ioctl  MIME  ( Multipurpose Internet Mail Extensions ) MTP  ( Media Transfer Protocol) NFC     (Near Field Communication) ODM OHA OMA  ( Open Mobile Alliance) OpenCores OpenGL ES OpenMax Skia Speech recognition SVG toolchain TTS V4L  ( Video4Linux   ) Webkit  YCbCr 

新年快樂之 Android C2DM資料收集

新年快樂之 Android C2DM資料收集 關於架構與想法 Mobile Application Architecture, Part 1 Mobile Application Architecture, Part 2 官網  Android Cloud to Device Messaging Framework Tutorial  Android Cloud to Device Messaging (C2DM) - Tutorial 而關於push notification  simple-google-android-c2dm-tutorial-push-notifications-for-android/ 更多筆記: Android C2DM (一):元件參數說明 Android C2DM (二):流程

拿到Ice Cream Sandwich之後 要怎麼吃呢?

圖片
拿到Ice Cream Sandwich之後 要怎麼吃呢? SE教大家  Ice Cream Sandwich – from source code release to software upgrade 1. 底層要先能動 - The Bring up phase: Getting Ice Cream Sandwich to work on our phones 2. 接著是framework要整 -  Integrating Android patches 3. 然後上層的App也要做測試 - Getting the software stable and adding localisation 4. 出貨一定要過認證 - The Certification and approval phase: Making sure the software and hardware is compliant 5. 最後新的feature也許有新的認證 - Additional approvals might be needed 真的不簡單阿 ~ 因為要花以上這些功夫,拿到ICS之後還是要到明年才會真的吃到 ~ 目前只有 Galaxy Nexus 可以今年出現  其他廠牌頂多只有搶鮮版可以過過癮 ! 更多4.0新聞 Acer 也將推出Android 4.0 平板更新 ! 另外 2012年新貨色 Acer Iconia Tab A200 各品牌 Android 裝置可升級 Android 4.0 機型整理

Google DevFest Taipei 2010 note

圖片
Google DevFest Taipei 2010 note Note: Introduction Android Building for Multiple Form Factors use DIP ! virtual pixel ! flot dipsize - dipsize * (new DisplayMetrics()).density Which version widget 1.5 quick search 1.6 data backup 2.2 What is new in Froyo ? DM C2DM Don't : polling Do : push when change com.google.android.c2dm.intent.REGISTER (Device to C2DM server) # https://android.api5.google.coom/c2dm/send/ (app server to C2DM server) project :  Android Cloud to Device Messaging Framework install to SD App Data Backup onRestore() Be cautious when back up sensitive data Be sure to synchronsize ! Market license Referral Tracking INSTALL_REFFERAL !! #http://code.google.com/mobilepr3 HTML 5 gs.statcounter.com   各家瀏覽器的支援程度  html5readiness.com 網頁相關資訊收集學習  caniuse.com 重要網站  html5rocks.com 投影片  goo.gl/WQOV Notification is not a WebKit API, will it in webkit source tree ? 其他html5文章: html 好威阿 Open Social ! OAuth use token instead of passwd At...

2011 ADL Taipei note

2011  ADL Taipei note UI Quality ? dpi ldpi : mdpi : hdpi : xhdpi 3 : 4 : 6 : 8 tvdip = 213 dp : sp(for text) smallest width -> sw design preview tool UI Patterns : Action  Bar contextual action bar stack action bar split action bar http://goo.gl/dxMtl Multi-Pane App Navigation contact > conttact detail -> email compose ->  email               (back)                              (up)                     do and don't ? hard accelerated default is true on ICS don't overuse fill_parent (beacause text ...............???) Android market feature new : Multiple APK support       Device Availability       localizr listing Commuication & Camera 1. Wifi direct High performance connection at a range WifiP2pManager App components BroadcastReceiver : state_change coneection_change p...

使用Eclipse 開發Android 如何更順 更Android

圖片
關於使用Eclipse 開發Android 如何更順 更Android 服用本篇可以 1. 讓Eclipse更順 2. 讓Code有Android Code Style 3. 讓Code可以使用internal api 1.  讓Eclipse更順 可以修改eclipse.ini 以應付越來越大的memeory使用 原本是這個 -Xms40m -Xmx256m -XX:MaxPermSize=256m 推薦使用 -Xms128m -Xmx512m -XX:MaxPermSize=256m 2. 讓Code有Android Code Style 參考 http://source.android.com/source/using-eclipse.html 需要兩個檔案 android-formatting.xml 以及 android.importorder 然後 Eclipse formatting Select Window > Preferences > Java > Code Style. Use Formatter > Import to import android-formatting.xml. Organize Imports > Import to import android.importorder. 3. 讓Code可以使用internal api 要修改build path 把Android SDK裡面的layoutlib.jar 加印來 ex   \android-sdk\platforms\android-13\data\layoutlib.jar Eclipse -> Java Build path -> Add Library -> User Library  -> New (System library 要打勾) -> Add Jar Eclipse 相關文章: set Android error log on Eclipse linux(ubuntu)環境下開發 Android 所遇到的Eclipse 設定問題 Android tutorial : Before HelloWorld

關於Git與ICS

圖片
之前有很多篇有關Git的介紹 在此推薦 Git魔法書 一次補完 ~!!! 其他文章: Adventure Book 2.0: 好物推薦: Git Adventure Book 2.0: most commonly used  git  commands Adventure Book 2.0: Repo 與 git Adventure Book 2.0:  Git  如何切換不同版本 另外推薦: [RD水電工不會修水管] Git 簡單使用情境教學 -- 2011/11/15 突然 Google 把ICS放出來了請看 http://source.android.com/source/downloading.html 基本上應該一招 $ repo init -u https://android.googlesource.com/platform/manifest -b android-4.0.1_r1 但實在太擠了,可以改用這招: ex.  git clone https://android.googlesource.com/platform/packages/apps/Launcher2.git 其他ICS相關文章: ICS 快要上市了但先review一下HC吧 Android 4.0  ICS  ice cream sandwich 冰淇淋來  ...

Android Widget 整理

圖片
1. app widgets with collections像一般的app widget一样,你主要代码应该在AppWidgetProvider的onUpdate()方法中。 2. 希望AppWidgetProvider的进程能够长久运行,那么你可以考虑在onUpdate() 中启动一个Service。 3. 

unable to access file: corrupted zip file

圖片
話說最近在Build Android Project有遇到一個問題 packages/apps/Calculator/src/ c om/android/calculator2/ History Adapter.java:65: cannot access org.xmlpull.v1.XmlPullParser bad class file: org/xmlpull/v1/XmlPullParser. c lass(org/xmlpull/v1: XmlPullPar ser.class) unable to access file: corrupted zip file Please remove or make sure it appears in the correct subdirectory of the classpath. view = mInflater.inflate(R.layout. his tory_item, parent, false); ^ 論壇上人說 如果你是使用apt-get install 来安装eclipse的话   使用apt-get remove  eclipse 但是實際上應該要做的是設定一些路徑,可以修改 .bashrc 加上這些                                                     export JAVA_HOME=/usr/lib/jvm/java-6- sun-1.6.0.13 export CLASSPATH=$JAVA_HOME/lib:$ JAVA_HOME/jre/lib:./ export PATH=$JAVA_HOME/bin:$JAVA_ HOME/jre/bin:$PATH:$HOME/bin 當然JAVA_HOME 是要自己去找一下的 -- 另外最近還有遇到一個妙問題 ...

把Android App變到Windows Phone上 !

圖片
新聞連結: 微軟開放Android App轉換平台,打造App Guy解決開發者困難 http://news.pchome.com.tw/science/bnext/20110613/index-13079366404040555005.html Microsoft courts Android developers with new API mapping tool http://thenextweb.com/microsoft/2011/06/09/microsoft-courts-android-developers-with-new-api-mapping-tool/ 實際使用網址: http://wp7mapping.interoperabilitybridges.com/Home/Library?source=Android From Search Beauty

Google I/O 2011 重點整理

圖片
話說Google I/O 2011 重點整理的文章好像很多, Google I/O 2011發表會重點總整理 Google I/O 2011發表會 Round 2 重點總整理 甚至還有一樣標題的 : MSN Google I/O 2011發表會重點總整理 跟著也出了一篇,不過說實在的個人覺得的重點就是 ICE Cream今年Q4要上場,手機平板通吃。 基本上應該就是Android 4.0 想到年初在趕3.0 年尾就變成 4.0 科技業真是變動很大阿。 再看看Google要 Music 要Video ,感想就是:內容為王。 想到 Acer的 Alive  整個就要大比拼啦 其他Google I/O文章: iosched : Google I/O Schedule App for Android Android 2.2 要來啦 ~  (是的 2010 Google I/O 還在2.2 現在一下就3.1 年底又要4.0) 其他Acer文章: Google一下 Acer Android 手機 !!! 關於PChome及Yahoo購物中心的Acer Android手機 關於最近三年來Acer 微巨服務 關於Acer產品的討論區

分析android app記憶體使用情況

圖片
分析android app記憶體使用情況 Memory Analysis for Android Applications 清新 健康 專業 其他文章: 關於Google的文章 關於Acer的文章

Google

本月熱門文章

水電行介紹---台北市中正區臨沂街71巷5上的友來來水電行---水電、廚具、爐具相關服務都有服務喔~~

水電行介紹---台北市中山區大直街34巷17號的泰新水電行‎—--成立24年,跟住家合ㄧ的在地水電行!