Search code examples
androidgoogle-mapsgoogle-play-serviceslocation-aware

Unable to make my app location aware


I am following the android tutorial on making your app location aware here
but when I run it in the emulator the below method

@Override
public void onConnectionFailed(@NonNull ConnectionResult connectionResult) {
    Log.i("state", "Connection failed: ConnectionResult.getErrorCode() = " + connectionResult.getErrorCode());
}

shows in the Logcat:

Connection failed: ConnectionResult.getErrorCode() = 9

Does anyone know what ErrorCode 9 means?


Solution

  • public static final int SERVICE_INVALID

    The version of the Google Play services installed on this device is not authentic.

    Constant Value: 9

    Source: ConnectionResult

    Are you running the emulator that uses the Google APIs?