Geolocation and Google Maps are two important features of most Android devices.
Geolocation is a feature which Android applications can use to obtain the position of the device. Geolocation uses either the GPS, the GSM network or Wifi to determine (with different levels of accuracy) the latitude and longitude of the device. It can also determine the altitude, bearing as well as speed of the device if possible.
The application to develop should display all relevant geolocation information when the user clicks on Where am I?!? The location should be automatically updated when the device moves.
Essential Android classes for geolocation include LocationManager, LocationListener and Location.
The application will have to be enhanced to display a Google Map of the position of the device instead of just textual information. This Google Map will be updated whenever the device moves.
To display a map from Google Maps in Android 3.0 and up, it is important to use the Google Play Services.
- Ensure that you have installed the Google Play services application on your physical device.
- Make sure that the Google Play services is setup properly for the project in Android Studio. Google Play Services includes the Google Maps capability.
- Google Maps requires an API Key to work. Obtain the key corresponding to the debug certificate.
- Finally, the AndroidManifest of the project as well as the layout need to be modified accordingly.
Once this is done, the idea is to use classes provided by Google to control with the map shown.
Rajnikant shah says
Complete Google map knowledge for android