Android Studio Emulator:身份验证失败。尝试联系服务器时超时

Android Studio Emulator:身份验证失败。尝试联系服务器时超时,android,google-maps,android-studio,google-maps-api-3,Android,Google Maps,Android Studio,Google Maps Api 3,我正在尝试学习安卓开发&第一次这样做是为了实践我的想法。我想用模拟器上的当前位置加载google地图 所提问题: 起初,我面临着这个问题 更改后问题得到解决: compile 'com.google.android.gms:play-services:9.0+ 我还通过从代码文件中给出的链接生成API_密钥来更正API_密钥。现在我没有得到那个错误,但仍然无法在模拟器上加载映射。这些似乎是连接问题&我也在清单文件中添加了权限。但问题依然存在。请指导我并提供您宝贵的建议 谷歌地图api.xml

我正在尝试学习安卓开发&第一次这样做是为了实践我的想法。我想用模拟器上的当前位置加载google地图

所提问题:

起初,我面临着这个问题

更改后问题得到解决:

compile 'com.google.android.gms:play-services:9.0+
我还通过从代码文件中给出的链接生成API_密钥来更正API_密钥。现在我没有得到那个错误,但仍然无法在模拟器上加载映射。这些似乎是连接问题&我也在清单文件中添加了权限。但问题依然存在。请指导我并提供您宝贵的建议

谷歌地图api.xml

AndroidManifest.xml


将此代码添加到应用程序manifiest

是否打开MapActivity,并显示未加载的白色地图?是正确的。它是白色屏幕,谷歌在底部我也有同样的问题,而且一切都设置正确…后来我发现问题是我在谷歌控制台上使用的API_键,点击你的api并使用Android api_键他们自动生成的一个:让我知道它是否有效我需要用api_键替换google_地图_键吗?是的,你必须将你的地图api键放入值中,直到,超时即将到来,它会使用互联网源作为我的PC吗?我在Emulator上检查它,而不是在移动设备上。它也能在模拟器上工作吗?连接到地图需要互联网并使用物理设备进行测试
<resources>
    <!--
    TODO: Before you run your application, you need a Google Maps API key.

    To get one, follow this link, follow the directions and press "Create" at the end:

    https://console.developers.google.com/flows/enableapi?apiid=maps_android_backend&keyType=CLIENT_SIDE_ANDROID&r=6C:42:DD:0A:5D:D3:E4:5E:79:C9:04:81:3A:7A:70:17:25:37:97:96%3Bcom.example.kapilj3.meetmeapp

    You can also add your credentials to an existing key, using this line:
    6C:42:DD:0A:5D:D3:E4:5E:79:C9:04:81:3A:7A:70:17:25:37:97:96;com.example.kapilj3.meetmeapp

    Alternatively, follow the directions here:
    https://developers.google.com/maps/documentation/android/start#get-key

    Once you have your key (it starts with "AIza"), replace the "google_maps_key"
    string in this file.
    -->
    <string name="google_maps_key" templateMergeStrategy="preserve" translatable="false">AIza_MY_ACTUAL_KEY</string>
</resources>
<uses-permission android:name="android.permission.ACCESS_FINE_LOCATION" />
<uses-permission android:name="android.permission.ACCESS_WIFI_STATE" />
<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="com.google.android.providers.gsf.permission.READ_GSERVICES"/>

<uses-feature
    android:glEsVersion="0x00020000"
    android:required="true"/>
   <!-- Goolge API Key -->
    <meta-data
        android:name="com.google.android.maps.v2.API_KEY"
        android:value="@string/google_maps_key" />