I\'ve tried to implement Google Maps v2 in my Android application, but unfortunately instead of maps I get this message:
Please try the following. It was successfully for me.
Steps:
Create a new emulator with this configuration:
Start the emulator and install the following APK files: GoogleLoginService.apk
, GoogleServicesFramework.apk
, and Phonesky.apk
. You can do this with the following commands:
adb shell mount -o remount,yourAvdName -t yaffs2 /dev/block/mtdblock0 /system
adb shell chmod 777 /system/app
adb push GoogleLoginService.apk /system/app/
adb push GoogleServicesFramework.apk /system/app/
adb push Phonesky.apk /system/app/
Links for APKs:
Install Google Play services and Google Maps in the emulator
adb install com.google.android.apps.maps-1.apk
adb install com.google.android.gms-2.apk
sdkmanager->extra->google play service
.google-play-services_lib
from androidsdk\extras\google\google_play_services
.Google has updated the Virtual Device targeting API 23. It now comes with Google Play Services 9.0.80. So if you are using Google Maps API V 2.0 (I'm using play-services-maps:9.0.0 and play-services-location.9.0.0) no workaround necessary. It just works!
I have already replied to this question in an answer to Stack Overflow question Trouble using Google sign-in button in emulator. It only works for Android 4.2.2, but lets you use the "Intel Atom (x86)" in AVD.
I think that it is easy to make it work for other versions of Android. Just find the correct files.
I recommend using the emulator by Genymotion instead of Google's emulators. It launches way faster and responds almost in real-time. It also supports Google Play Services and therefore Google Maps.
Give it a try! Here is a blog post which helps you setting up the emulator.
You need to try on an emulator with the Google API's version. Each platform has two versions, Android and Android+Google APIs. Ensure that when you create the AVD, you select the Google APIs version on target field.
And the page Ensure Devices Have the Google Play services APK can be also helpful.