










































Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
This page cannot be seen from the preview
Don't miss anything!











































1
2
Geolocalization Identification of the real-world geographic location of an end-user.
(^) explicitly by name (^) LOCALIZATION THROUGH GPS (^) LOCALIZATION THROUGH WI-FI (^) LOCALIZATION THROUGH CELLULAR NETWORK (^) LOCALIZATION THROUGH GPS (^) LOCALIZATION THROUGH WI-FI (^) LOCALIZATION THROUGH CELLULAR NETWORK
4
EP -1 : Install and Setup Google Play Service SDK Window Android SDK Manager Installed packages Check Google Play and Google Repository are installed , or install them otherwise Check Google Play and Google Repository are installed , or install them otherwise http://developer.android.com/google/play- services/setup.html
5
(^) Note: Existing keys from a Google Maps Android v1 application, commonly known as MapView, will not work with the v2 API. The Google Maps Android API uses a new system of managing keys. (^) Note: You need an Android API key , not a browser key. You can use the same API key for your Google Maps Android API apps and your Google Places API for Android apps. (^) Access your project's API keys and other credentials as follows:
1. Go to the Google Developers _Console(https://console.developers.google.com/)
7
“ Location-based services ” is an umbrella term that describes the different technologies you can use to find a device’s current location. (^) The two main LBS elements are: (^) Location Manager - Provides hooks to the location- based services. (^) Location Providers -Each of these represents a different location-fi nding technology used to determine the device’s current location. (^) Using the Location Manager, you can do the following: (^) Obtain your current location (^) Follow movement (^) Set proximity alerts for detecting movement into and out of a specified area (^) Find available Location Providers
8 Access to the location-based services is provided by the Location Manager. (^) To access the Location Manager , request an instance of the LOCATION_SERVICE using the getSystemService method, as (^) Before you can use the location-based services, you need to add one or more uses-permission tags to your manifest. (^) The following snippet shows how to request the fi
10
Depending on the device, you can use several technologies to determine the current location. Each technology, available as a Location Provider , offers different capabilities including differences in power consumption, accuracy, and the ability to determine altitude, speed, or heading information. (^) Finding Location Providers The LocationManager class includes static string constants that return the provider name for three (^) Location Providers: (^) LocationManager.GPS_PROVIDER (^) LocationManager.NETWORK_PROVIDER (^) LocationManager.PASSIVE_PROVIDER The GPS and passive provider requires fine
11 To get a list of the names of all the providers available (based on hardware available on the device,and the permissions granted the application), call getProviders , using a Boolean to indicate if you want all, or only the enabled , providers to be returned: (^) Finding Location Providers by Specifying Criteria (^) Use the Criteria class to dictate the requirements of a provider in terms of accuracy, power use(low, medium, high), financial cost, and the ability to return values for altitude , speed , and heading. (^) Specifies Criteria requiring
13 In terms of horizontal and vertical accuracy , (^) high accuracy represents a requirement for results correct to within 100m. (^) Low accuracy Providers are correct to more than 500m, (^) Medium accuracy Providers represent accuracy between 100 and 500 meters. (^) When specifying accuracy requirements for bearing and speed , only ACCURACY_LOW and ACCURACY_HIGH are valid parameters. (^) Having defined the required Criteria, you can use (^) getBestProvider to return the best matching Location Provider or (^) getProviders to return all the possible matches. (^) getBestProvider to return the best Provider for
14 If more than one Location Provider matches your Criteria, The one with the greatest accuracy is returned.
(^) Power use
(^) The criterion for allowing a device with monetary cost is never implicitly relaxed. If no provider is
16
You can find the last location fix obtained by a particular Location Provider using the get Last- Known Location method , passing in the name of the Location Provider. The following example finds the last location fix taken by the GPS provider: getLastKnownLocation does not ask the Location Provider to update the current position. If the device has not recently updated the current position, this value may not exist or be out of date. (^) The Location object returned includes all the position information available from the provider that supplied it. This can include
17
finds the device’s last known location using the GPS Location Provider. (^) This example assumes that (^) you have enabled the GPS_PROVIDER Location Provider using the techniques or that you’re running it on a device that supports GPS and has that hardware enabled. (^) In order to work, the device or Emulator must have recorded at least one location update. In the case of a device, this is most easily achieved by starting the Google Maps application; on an Emulator, enable location updates as described
19
20 (^) Override the onCreate method of the WhereAmI Activity to get a reference to the Location Manager. (^) Define LocationManager and Provider Class (^) Call getLastKnownLocation to get the last known location , and pass it in to an updateWithNewLocation method stub.