How To Install Google Apps on Visual Studio Android Emulator

Introduction:

In this article, we will talk about how to install Google apps on visual studio android emulator. We need to install Google Apps on emulator, if we need to test the applications which access Google services like Google Maps. So let`s get started.

Requirement:

Download the proper Google Play Services .zip file. It should match the version of android installed on emulator.

Steps:

  1. Start the visual studio android emulator (I have started my visual studio android emulator which has Lollipop version API 21). Image is as shown below (F: 1),

    apps

  2. Click on Additional Tools icon on the emulator as shown below (F: 2).

    Tools

  3. Select the SD Card tab as shown below (F: 3),

    sd

  4. Create a new folder on any drive and browse that folder to create a virtual SD card (F: 4). (I have created a new folder called SDCardAPI21 and selected that folder to create the virtual SD Card).

    tools

  5. Now click on “Pull from Sdcard” button. After some processing, it will create a directory structure in our selected folder as shown below (F: 5).

    folder

  6. Now copy Google Play Services .zip file in Download folder. Location for Download folder is SDCardAPI21\0\Download where SDCardAPI21 is the folder which we have created in Step 4.

  7. Now let`s go back to our SD Card tab and click on “Push to SD Card” button as shown below (F:6). It will take a few moments for processing. It will copy our Google Play Services .zip file to emulator.

    emulator

  8. Go to the location where Android SDK is installed. Then go to the platform-tools folder. Now to open the command prompt at this location, hold the SHIFT key and Right click using mouse in that folder. We will get a new option in Right click menu Open command window here as shown below (F: 7). Select that option; it will open up the command prompt at AndroidSDK\platform-tools location.

    open

  9. Run the following command to display the list of running devices/emulators. adb devices. ADB (Android Debug Bridge) is a command line tool which helps us to communicate with running emulator instance or connected android device.

    After executing the above command, we should get the information about our running android emulator as shown below (F: 8)

    emulator

  10. Run the following command to start a remote UNIX shell to our emulator.

    adb shell.

  11. Run the following command to check that our Google Play Services .zip file is copied to emulator.

    ls /sdcard/Download

    Output of the above command is as shown below (F: 9)

    output

    As we can see in above image, our Google Play Services .zip file is copied to emulator.

  12. Now run the following command to install the Google Apps on emulator. Install_zip.sh /sdcard/Download/gapps-lp-20141109-signed.zip.

  13. Once the installation is complete, we need to restart the emulator.

  14. After restart, we should be able to see Google Apps on our emulator as shown below (F: 10),

    output

Conclusion:

In this article, we talked about how to install Google apps on visual studio android emulator. I hope you enjoyed reading the article.

Reference: Stack Overflow

Up Next
    Ebook Download
    View all
    Learn
    View all