0

I did the things described in this article:

When the application starts on real device HTC Desire 500 Dual, Android version 4.1.2 is not shown google map. Showing a black screen with the logo of google and inactive "+" and "-".

I use this files:

AndroidManifest.xml

<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
  package="gogo008.kermi.geo.v2"
  android:versionCode="1"
  android:versionName="1.0">

    <uses-permission android:name="android.permission.INTERNET"/>
    <uses-permission android:name="android.permission.ACCESS_NETWORK_STATE"/>
    <uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE"/>
    <uses-permission android:name="com.google.android.providers.gsf.permission.READ_GSERVICES"/>

    <!-- The following two permissions are not required to use Google Maps Android API v2, but are recommended. -->
    <uses-permission android:name="android.permission.ACCESS_COARSE_LOCATION"/>
    <uses-permission android:name="android.permission.ACCESS_FINE_LOCATION"/>

    <uses-feature android:glEsVersion="0x00020000" android:required="true"/>

<application android:label="@string/app_name" android:icon="@drawable/ic_launcher">
    <meta-data android:name="com.google.android.gms.version" android:value="@integer/google_play_services_version" />

    <activity android:name="KermiGeo_v2"
              android:label="@string/app_name">
        <intent-filter>
            <action android:name="android.intent.action.MAIN" />
            <category android:name="android.intent.category.LAUNCHER" />
        </intent-filter>
    </activity>
    <meta-data android:name="com.google.android.maps.v2.API_KEY" android:value="AIzaSyCTNkkaXiTHasvFzrHek1RYMj4AzoUHIeA"/>
</application>
</manifest>

res/layout/main.xml

<?xml version="1.0" encoding="utf-8"?>
<fragment xmlns:android="http://schemas.android.com/apk/res/android"
    android:id="@+id/map"
    android:layout_width="match_parent"
    android:layout_height="match_parent"
    android:name="com.google.android.gms.maps.MapFragment"/>

src/gogo008/kermi/geo/v2/KermiGeo_v2.java

package gogo008.kermi.geo.v2;

import android.app.Activity;
import android.os.Bundle;

public class KermiGeo_v2 extends Activity
{
    /** Called when the activity is first created. */
    @Override
    public void onCreate(Bundle savedInstanceState)
    {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.main);
    }
}

Info from google console is:

Key for Android apps (with certificates) API key: AIzaSyCTNkkaXiTHasvFzrHek1RYMj4AzoUHIeA

I usе debug certificate fingerprint.

Can anyone help me?

Andrea
  • 11,801
  • 17
  • 65
  • 72

1 Answers1

1

Check DDMS for errors. I found using DDMS the correct SHA1 hash and package name to be used in google console android maps setup.

Shawlz
  • 538
  • 3
  • 11
  • Thanks for your post! I did not understand where is the error. I did it again in a new project. Now it works perfectly :-) – user3054412 Dec 27 '13 at 17:25