顯示具有 安裝 標籤的文章。 顯示所有文章
顯示具有 安裝 標籤的文章。 顯示所有文章

2013年1月8日 星期二

筆記,關於android找不到裝置。


這張照片拍得還不錯,不過跟主題無關。

常常在用eclipse跑實機的測試時會出現安裝失敗的訊息:

[2013-01-08 01:44:35 - MoneyCare_1_0_3] Failed to install xxxxxxxx_xxx_xxx_x.apk on device 'HT24LW103531!
[2013-01-08 01:44:35 - MoneyCare_1_0_3] (null)
[2013-01-08 01:44:40 - MoneyCare_1_0_3] Failed to install xxxxxxxx_xxx_xxx_x.apk on device 'HT24LW103531': null
[2013-01-08 01:44:40 - MoneyCare_1_0_3] com.android.ddmlib.InstallException
[2013-01-08 01:44:40 - MoneyCare_1_0_3] Launch canceled!

或是timeout:

[2013-01-08 01:56:52 - MoneyCare_1_0_3] Failed to install xxxxxxxx_xxx_xxx_x.apk on device 'HT24LW103531': timeout
[2013-01-08 01:56:52 - MoneyCare_1_0_3] Launch canceled!

或是連結失敗:

[2013-01-08 02:19:31 - MoneyCare_1_0_3] Failed to install MoneyCare_1_0_3.apk on device 'HT24LW103531': Connection refused: connect
[2013-01-08 02:19:31 - MoneyCare_1_0_3] java.net.ConnectException: Connection refused: connect
[2013-01-08 02:19:31 - MoneyCare_1_0_3] Launch canceled!


導致安裝app不成功,怎麼辦呢?

根據小書的經驗,讓我把成功的經驗記錄下來。

我們可以循序採取下列步驟:
  1. 拔除手機線,再試一次。
  2. 如果在DDMS的Devices裡面沒有裝置,可以等一下,他可能在讀取;或是再試一次。
  3. 如果找到裝置了但是還是安裝失敗:
    1. 拔除手機線&關閉eclipse
    2. 開啟電腦中啟動工作管理員
    3. 再"處理程序"中會找到"adb.exe"或是"adb.exe *32"的程序,結束它。
    4. 再重啟eclipse&&裝上裝置。
我想第三個方法應該已經是大絕招了,如果上面都失敗...
請檢查手機中有沒有設定"允許未知來源"的安裝權限吧!

話說,先檢查"允許未知來源"才是第一個步驟。
















2012年3月18日 星期日

說說。安裝android

安裝android需要幾個重要的東西,要注意我們用的電腦是32位元還是64位元的喔:

  1. Java JDK(Java SE Development Kit ),我們需要這個才能使用Java的開發環境。
    1. 注意喔!如果只是想運行Java環境的遊戲,只要安裝JRE就可以了喔!
    2. 然後,這是Java最新的API,參考參考很重要。
  2. Eclipse,是一個很強大的IDE。
    注意如果要開發Java的話(廢話),要選Eclipse IDE for Java Developers或是Eclipse IDE for Java EE Developers這兩個,後者比較完整,企業級的吼。
  3. Android SDK,這是核心啦!看你的電腦是什麼系統的便安裝哪個唄。
  4. ADT套件。是說Eclipse要安裝就要先裝上這個套件。
    以下是安裝說明:
    1. Start Eclipse, then select Help > Install New Software....
    2. Click Add, in the top-right corner.
    3. In the Add Repository dialog that appears, enter "ADT Plugin" for the Name and the following URL for the Location:
      https://dl-ssl.google.com/android/eclipse/
    4. Click OK
      Note: If you have trouble acquiring the plugin, try using "http" in the Location URL, instead of "https" (https is preferred for security reasons).
    5. In the Available Software dialog, select the checkbox next to Developer Tools and click Next.
    6. In the next window, you'll see a list of the tools to be downloaded. Click Next.
    7. Read and accept the license agreements, then click Finish.
      Note: If you get a security warning saying that the authenticity or validity of the software can't be established, click OK.
    8. When the installation completes, restart Eclipse.
這裡有網路空間分享的Eclipse,是已經安裝了ADT套件的。 

追蹤者