ibeacon

Count while in background (NSTimer for more than 3 mins)

半腔热情 提交于 2019-12-06 19:47:25
Is there any way to run NSTimer for more than 3 mins in background? I have to create simple app that uses `locationManager(manager: CLLocationManager, didRangeBeacons beacons: [CLBeacon], inRegion region: CLBeaconRegion)` for scan my beacons. I have run into problem when I needed to check if user is exactly 10 seconds near closest beacon. I created var timer: NSTimer? var lastClosestBeacon: CLBeacon? { didSet { timer?.invalidate() timer = NSTimer.scheduledTimerWithTimeInterval(10, target: self, selector: "showLocalNotification", userInfo: nil, repeats: false) // NSRunLoop.mainRunLoop()

iBeacon protocol clarification

橙三吉。 提交于 2019-12-06 15:23:04
问题 I am trying to understand more about the new Apple iBeacon protocol and how it would apply to other devices. I have seen that the protocol itself has been reverse engineered: http://developer.radiusnetworks.com/2013/10/01/reverse-engineering-the-ibeacon-profile.html which is good news, but I have some further questions about the protocol. Is the protocol designed to allow custom text messages to send to receiver clients? Such as "welcome to my shop" as opposed to just proximity to a certain

How to send some data between iBeacons

别来无恙 提交于 2019-12-06 14:32:18
问题 I started to develop with iBeacon technology. I know how connect, calculate proximity ect ect.... But one time that the connection is established, how I can send some text data between sender and receiver? There is a method (for example) can I use in some way the self.peripheralManager.accessibilityLabel Is enought also the deviceID that I can manage it with a WebServer Thank you.... 回答1: The iBeacon protocol is only for transmitting / discovering beacon IDs and calculating their proximity.

iBeacon Region monitoring: Not resumed when rebooting the phone EXCEPT if I set location background mode?

百般思念 提交于 2019-12-06 13:22:54
问题 all day I tested the monitoring of beacons my app does. in general it works ok: notifications in foreground work notifications in background work BUT after a reboot it doesn't work until I launch ANY app that uses BluetoothLE after I do that it works fine for my app as well! But if I set UIBackgroundMode location in my plist though, my app gets region notifications just fine even after a reboot. So... is that it? or whats the deal here? :D this is under ios 7.1.1 btw The code is very minimal:

Proximity range for Beacons changes back and forth even when the App is in the same place

折月煮酒 提交于 2019-12-06 09:32:32
问题 Beacon Proximity range changes the proximity response as Near - Immediate - Far, even while the ios Device remains in the same place. As I open a view when the proximity response is Near. I get the proximity response back and forth, Near - immediate then Near. It shows up the view again and again How can we solve this issue. Is there any event handler. Thanks. 回答1: The proximity and accuracy values appear to be quite 'noisy'. It can also depend on your environment. Water (and therefore people

Bluetooth Low Energy Android - Search in Background

二次信任 提交于 2019-12-06 08:33:36
I would like to know whether it is possible to check in the background if someone enters or leaves the a beacon Region? In iOS for example you can use the methods didEnterRegion or didExitRegion to send notifications from the background. Is there any native possibility or has someone a workaround? Android doesn't have any "native" iBeacon capability at all, but you can see iBeacons using my company's open source Android iBeacon Library , which has APIs similar to those native to iOS 7. In the case of iOS, the CLLocationManagerDelegate gives you access to the didEnterRegion and didExitRegion

NotificationManager Error Android Studio

ⅰ亾dé卋堺 提交于 2019-12-06 06:58:14
I have write a code to have pop-up Notification when in range of Beacon. my code for notification like this: private void showNotification(String message){ Log.d("Hay8","DCM8"); Intent intent = new Intent(context, MainActivity.class); Log.d("Hay9","DCM9"); PendingIntent pendingIntent = PendingIntent.getActivity(context,0,intent,PendingIntent.FLAG_UPDATE_CURRENT); Log.d("Hay10","DCM10"); NotificationCompat.Builder builder = new NotificationCompat.Builder(context,"default") .setSmallIcon(android.R.drawable.ic_dialog_info) .setContentTitle("Notification1") .setContentText(message) .setDefaults

iBeacon - Difference between proximityUUID and region.identifier

泄露秘密 提交于 2019-12-06 03:44:24
问题 I am a bit confused about the importance of a CLBeaconRegion UUID and the string identifier. If my CLBeaconRegion already has an unique ID, what is the point of forcing the usage of an additional, non-unique string identifier? Is it purely "cosmetic"? Since users will not be able to scan and connect to beacon regions as they do with WiFi (and SSIDs) for example, and since the receiver app needs the CLBeaconRegion pre-coded and pre-defined in order to enter and range for beacons in a region,

Eddystone beacon detecting issue

房东的猫 提交于 2019-12-06 00:24:04
Here is a code I use to detect Eddystone using iPhone iOS 9: - (void)viewDidLoad { [super viewDidLoad]; if ([CLLocationManager locationServicesEnabled]) { _locationManager = [[CLLocationManager alloc] init]; self.locationManager.delegate = self; self.locationManager.pausesLocationUpdatesAutomatically = NO; [self.locationManager requestAlwaysAuthorization]; NSUUID *uuid = [[NSUUID alloc] initWithUUIDString:@"f7826da6-4fa2-4e98-8024-bc5b71e0893e"]; NSString *bundleIdentifier = [[NSBundle mainBundle] bundleIdentifier]; CLBeaconRegion *beaconRegion = [[CLBeaconRegion alloc] initWithProximityUUID

Local Notification When didEnterRegion?

眉间皱痕 提交于 2019-12-05 23:59:36
I have the following code which work perfect when app terminated. -(void)beaconManager:(id)manager didEnterRegion:(CLBeaconRegion *)region{ UILocalNotification *notification = [UILocalNotification new]; notification.alertBody = @"TEST NOTIFICATION"; notification.soundName = UILocalNotificationDefaultSoundName; [[UIApplication sharedApplication] presentLocalNotificationNow:notification]; } But When I do the following: -(void) createTestNotification { UILocalNotification *notification = [UILocalNotification new]; notification.alertBody = @"TEST"; notification.soundName =