Tuesday, September 27, 2011

Deploying Android Apps: Part 2

This is part two of "Deploying Android Apps" blog series and in this we will explore more details about how to deploy non-market apps on device.
Before you install any non-market app on your device, you have to make sure that your device is ready to install apps from ‘unknown sources’.  To do this, navigate to Menu -> Settings -> Applications and check the box marked ‘Unknown Sources’ (as shown in Fig 1). 
Note: On some devices you will not get this 'unknown source' option or it may be non-editable.
 
Figure 1: Enabling installation from 'Unknown Sources'
Figure 2: Installation error for Non-market apps

1       Using File Explorer

  • Install file manager – As Android does not have native file explorer feature/app to browse the data on your SD card, you need to install file manager app from Android market. There are lots of file explorer apps available, but my personal favorite is ES File Explorer. You can use any of the below mentioned file manager apps
  1. ES File Explorer
  2. ASTRO File Manager
  3. File Expert
  4. File Manager
  5. eFile
  • Copy APK file to SD card – Once you have installed file explorer app, connect your device to PC using USB cable. Mount the SD card and copy the required .apk file on SD card.
  • Install APK – Using file explorer app on device you navigate to the APK file and click on it. Follow on screen instructions to install the app. Different file explorer apps will show different options before actual APK installation starts.

2       From Website

  • Host the APK file on your website. Create webpage which will have hyper link to APK file. Use this webpage or direct link of APK file in your Android device browser.
  • Web server should have the APK mime type set up (application/vnd.android.package-archive)
  • Browser will download the APK file
  • Clicking on downloaded APK file in browser’s ‘Downloads’ section will start installation procedure

3       Using Dropbox

Dropbox is really a versatile app and is a waste if we don’t fully utilize it. The method is simple. In your computer, download the apk file to your Dropbox folder. Let it finish syncing. In your phone, open the Dropbox app, navigate to the folder where you keep the apk file, click on it. Dropbox will then download the apk file. The usual installation follows


4       Using Online APK Installer

The online apk installer is a web app created by a helpful XDA-Developers forum member htc-hd2, with the aim to make manual installation of an .apk file much easier. It is useful if you want to share an apk file with a friend. Following figure shows steps involved in this method.

Figure 3: Online APK Installer

  • Upload file - First navigate to http://www.apkinstall.com site. Click ‘Browser Files…’ button and select the APK file to upload on server. Uploaded file will remain active for 15 minutes only.
  • Scan QR code – Once APK file uploaded on site, QR code will appear on site. You can scan this QR code with barcode scanner on device. Once the QR code has scanned, you can click on the link to download the APK file straight to your device
  • Install APK - After the APK file has downloaded to your Android device you can install it by simply clicking on it and navigating through the installation instructions.

5       Using ADB

  • Install Android SDK on your desktop. You also need to install USB drivers to connect the device to your PC.
  • Go to settings->SD Card and Phone Storage->Disable Use for USB storage. You can enable it again later.
  • Now just open command prompt on your PC and type ‘adb install path/file.apk
    • Where path is the full path to the APKfile and file is the name of APK file.
  • Your application will get installed on device.

Deploying Android Apps: Part 1

This two part blog series describes different deployment methods for Android applications. First part details out deployment methods for market apps. Second part is about non-market app deployment which is nothing but manual app installation on device.

 

In this part one we will discuss how we can deploy the apps which are published on Android Market. Basically there are two methods for deploying market apps. First and most frequently used method is via Market App. Remote install is another method which is less used but will be very useful. These two methods are explained below in detail.

 

1       Android Market App

Installing apps using Android Market app on device is very straightforward. You need to login to Google service and open the Android Market app. It lists all the apps available/compatible to your device. Select any of the application and click install. Selected app will get downloaded and installed on your device.

Figure 1: Android Market App

2       Remote Install through Android Market Website

  • Go to https://market.android.com on your desktop browser
  • Login with Gmail account
  • Browse the apps and select the app you want to install
  • It will show app details along with below options (Fig 2)
  1. If selected app is free then you can see ‘INSTALL’ button just below the application icon
  2. If app is already downloaded you can ‘INSTALLED’ button instead of ‘INSTALL’
  3. For paid apps you will get option to buy it

Figure 2: Android Market Remote Install
  • Google will find all the devices on which you are using any of the Google service using same Gmail ID. It will list out all the devices along with compatibility details for the selected app.
  • After clicking on ‘INSTALL’ or ‘INSTALLED’ button, popup window will be shown which will have device list and permission details for the selected app. Here user will have option to select one of the devices from list and remote install that app on that device.  (Fig 3)

Figure 3: Android Market Remote Install Options
 
  • After clicking on ‘Install’ button on above popup window, you can notification bar on your Android device which tells that it is downloading and installing the app. This will be the same app you selected on Android Market website.