We have integrated Plot Projects for monitoring geo fences. When using Apples region monitoring we can simulate location when running the project from Xcode, tried to do the same but not getting notification from Plot, how can I simulate location and get notification for testing purpose?
Thanks In advance,
To simulate a location on a device attached to the Xcode debugger, you can use the Debug->Simulate Location menu item in Xcode.
You can either use one the pre-set locations or add your own GPX file. A GPX file can contain a series of locations and Xcode will simulate movement between those locations in a loop.
Don't forget to select "Don't simulate location" when you are done or the location will still be simulated until you reboot the device.
If someone is looking for the answer, put your phone in airplane mode and simulate location and switch off airplane. You will get push notification. If you don't get, restart the phone and try simulate location with airplane off.
Related
I am developing an iOS app with Xamarin.iOS.
I have granted permissions to use Location Services, and the Location icon is visible in the Status Bar as long as the app is running.
However, my app needs to get the current location on one screen only - the rest of the time location is not needed.
Is it possible to turn off (hide) the Locations icon when app is not really using it?
Answers I found are for old iOS versions or work on jailbroken phones. It is my understanding that Apple is preventing this now. I would appreciate a confirmation if this is at all possible or not. Or if it is possible - some Xamarin / Objective-C /Swift examples would be great.
U mean the airplane ICON in status bar?
This ICON will show when APP using location service, try to stop or remove your location request or mapView, your map SDK have their own interface, like:
locationManager = [[CLLocationManager alloc]init];
[locationManager stopUpdatingLocation];
and be sure other APP not using location service.
but it NOT sure the service will stop immediately, location manager just a monitor to system.
You can use requestAlwaysAuthorization instead of requestWhenInUseAuthorization on CLLocationManager.
NOTE : Provide the related NSLocationAlwaysUsageDescription in the
info.plist file, and then Blue Banner will not display.
Trying to develop my first application which will just be side loaded to my device. I am unsure if I can even do what I'm looking for; I'm trying to change the current location on my device via my application. I know this is done with the Xcode debugger but can it be done solely on the application with no connection to the computer? Basically I have a few buttons, each one I want to change the location to somewhere different. Do I just code the coordinates to set with the button and thats all? Will this show on my maps application and such? Thanks.
What you ask is not possible. The GPS hardware is what reports location to the phone. Xcode is able to do this because it is reporting location to the simulator, which has no GPS hardware on its own
There are two approaches for showing an app/app suggestion (incase not installed) on the iphone lock screen / app switcher. One is GPS based, in which the IOS decides which app to show as a suggestion. Another is beacon based, in which a particular beacon is identified.
If location services are enabled for multiple apps and say all these apps are also using beacon based approach to show their icons on the lock screen left corner, which app icon will be shown by the IOS?
Since location services are enabled for these apps,and say there is another relevant app which is NOT using beacon based approach (using just the GPS based approach), can IOS give preference to beacon based apps over the GPS based this new app.?
For instance, Estimote’s NYC office is on the same block as an Equinox gym and our phones intelligently and automatically alert us to use that app. It’s super easy and intuitive to open the app while walking into the gym - and in the process, streamline the check-in flow with the gym’s front desk. However, because it solely uses GPS geofences, the accuracy is poor. We actually get the Equinox icon over 1 block away, and there is no control for the brands or stores (in this case Equinox) on how this appears.
Apple's suggestion of apps not installed on the phone based on proximity uses an undocumented technique. While I have verified it uses GPS as an input, I have never been able to confirm that beacons are used at all.
Regardless of whether beacons are used, because this is an undocumented feature, it is unlikely you will find a way to customize the behavior.
AFAIK, Apple has never shared the implementation details of how the lock screen icon AKA "suggested apps" feature works.
However, we did some experiments at Estimote and noticed that being inside a CLRegion (both the "GPS" CLCircularRegion, and CLBeaconRegion work) that an app monitors for via Core Location, consistently makes the app's icon show up on the lock screen. So it seems that both beacons and GPS location fall into the same mechanism that governs the location-based suggestions. (Note that in iOS 9, that's not just the lock screen icon, but also a bar at the bottom of the app switcher.)
Unfortunately, we weren't able to establish what happens if you're inside multiple qualifying CLRegions, belonging to different apps. We suspect it might have something to do with the order in which the apps register regions for monitoring, but were never able to get consistent results.
Furthermore, since this whole behavior is undocumented, Apple can change it at any time. Just something to be aware of.
Side note: handoff always trumps suggested apps.
Our app uses location services, and registers in the normal way. We have an issue on 1 (!) iPhone where it's not showing in the Location Services, no matter what we do. The question is, does anyone know if this is a bug in iOS, or could there be something we're not doing?
Any thoughts welcome.
The app needs to trigger location settings to appear open up Facebook on ur phone click on the top left corner then press on nearby and allow it once that is done Facebook will appear under location settings
The best way to trigger facebook location services is to go to settings in your facebook app, next go to events. In events you will find a setting icon you need to click that. it will popup location permissions. Select while using.
If you can't find the setting icon in events tab, try to create a new event and it will ask you for location.
I'm learning to develop iOS apps and I try them on simulater only. Now, in my app I use CLLocationManager to get my current location coordinates. But when I run the app no matter where I am I get the same results for all the coordinate values(altitude,longitude,latitude). They do not change even if I move to another location. What I wonder is how does CLLocationManager get values? If it does not work on simulater then where do the values that never change come from? According to the coordinates I guess it's a default value that shows London if no coordinates are available.
Try Resetting the iOS Simulator, erasing all applications and settings.
And when you run CLLocationManager using application, it will probably ask for permission to use location, something like what you would see in you device.
I've been using iOS Simulator, and it gives location of my computer for the simulator all the time. I guess it's affected by your internet connection and IP address. Since many computers don't come with GPS, it's the only way to know the location of the computer.
The simulator always gives the location of Apple headquarters at Cupertino. It does not use computer's gps or location.
Simulator may use skyhook to check your location which is bounded to WiFi hotspot (if it was added with it's coordinates) and if you move in radius of WiFi coverage than your location won't be changed at all.
On the menu bar, go to Debug, then select Location, Custom Location and then you can input coordinates to simulate from. The Simulator will not always provide you the same feedback as a device would.