I am trying put a pin on User's current location. Picking location from LocationManger
and assigning it to MKAnnotation
. But when I run the application, Map show users location and Pin
location at different places on Map. Not very far but I am wondering why it's not same. Where as both custom pin and user's location are same on simulator.
Below is some of sample code.
self.locationManager = [[CLLocationManager alloc] init];
[self.locationManager requestWhenInUseAuthorization];
[self.locationManager startUpdatingLocation];
MyLocation *mylocation = [[MyLocation alloc] initWithName:@"name" address:@"address" coordinate:self.locationManager.location.coordinate] ;
Do I need to set some accuracy level? wondering how MKMapView is showing location.