core-bluetooth

How many devices we can pair via Bluetooth to iPhone?

假装没事ソ 提交于 2019-11-29 02:30:46
问题 Can anyone tell me how many devices can we pair via Bluetooth to iPhone at a time..need help..till now i have not got the exact number. 回答1: As it stands in iOS 6.1.4, the current limit for Bluetooth Low Energy devices is 10 simultaneous CONNECTIONS (at least on the NRF8002 chipset). Although the BLE spec says it can in theory have an infinite number of connections, the connection will time out when you try to add an 11th device. As for the pairing table, I've previously had two additional

iOS 6 CoreBluetooth Pairing / Forgetting (2 questions)

一曲冷凌霜 提交于 2019-11-29 00:24:03
问题 We have a bondable (when we connect we are asked to Pair, see question 2) Bluetooth 4.0 peripheral that we have manufactured and have written an iOS app for. Question 1 Is it possible in iOS 6 with CoreBluetooth to remove our peripheral from the iOS Bluetooth Settings from within our app or is this restricted to only going to iOS Settings / Bluetooth / Our Peripheral and "Forget this device". What we are trying to do is when we remove our peripheral from within our app, we expect this

Reading a BLE Peripheral Characteristic and checking its value?

女生的网名这么多〃 提交于 2019-11-28 23:58:04
I'm writing an app using Swift on Xcode that connects to a bluetooth BLE peripheral. I've established a connection to a the device, and want to read some data from a specific characteristic (specifically FFF1 in service UUID FFF0). I'm able to request a read of characteristics using the following code if the characteristic that I want to find info for is characteristicx : peripheral.readValueForCharacteristic(charactericsx) What I want to know is this: How do I check that this read value is what I'm looking for. I want to be able to do an if statement to check my value against the discovered

How can I clear the CoreBluetooth cache on MacOS?

不打扰是莪最后的温柔 提交于 2019-11-28 23:09:09
问题 I'm developing a Bluetooth LE device and am having trouble because of MacOS's caching of the services. If I try to delete a service or change its UUID on the device I'm developing, the change doesn't show up on the Mac and instead I continue seeing the old list of services and UUIDs from the device. I tried going to another Mac that hadn't paired with my device and it saw the new list of services with the correct UUIDs, so it seems to be a caching issue with my development Mac. I found the

Background time issue for Bluetooth LE app for Iphone 4s

心不动则不痛 提交于 2019-11-28 19:17:26
I am using core-bluetooth framework for my app in Iphone-4s. This is typically has to be a background app which can run as longer as possible. Now it is only running for 40 min - 1 hour max. I am hoping for at least 1 day or so. For this "bluetooth-central" value is added in "Required background modes" key in .plist file. It seems like my app is going to "suspend" mode, at the end. since when I open the app again (background to foreground state) it is sending the notification again, it means the bluetooth connection is still connected and BLE-device is still sending notification. If i press

Sending image file over Bluetooth 4.0 LE

左心房为你撑大大i 提交于 2019-11-28 18:54:25
I am trying to send an .png image file from one iOS Device to another over Bluetooth 4.0 LE. I am able to simple pieces of data like strings, but unable to successfully send and utilize image files. In the Peripheral device, I start out with this pictureBeforeData = [UIImage imageNamed:@"myImage.png"]; NSData *myData = UIImagePNGRepresentation(pictureBeforeData); Then I make myData a characteristic's value. _myCharacteristic = [[CBMutableCharacteristic alloc] initWithType:_myCharacteristicUUID properties:CBCharacteristicPropertyRead value:myData permissions:CBAttributePermissionsReadable]; In

How to detect nearby devices with Bluetooth LE in iOS 7.1 both in background and foreground?

半城伤御伤魂 提交于 2019-11-28 18:48:50
I have an app that needs to detect a nearby (in range for Bluetooth LE) devices running the same application and iOS 7.1. I've considered two alternatives for the detection: Having the devices act as iBeacons and detect iBeacons in range Using CoreBluetooth (like in Vicinity implementation here ) to create a BLE peripheral, advertise that and scan the peripherals It seems that the option 1 is out of the question because: It may take at least 15 minutes for iOS to detect entering a beacon region when the application is running background (iOS 7.1) Option 2 seems the way to go, but there are

Bluetooth Low Energy encryption and data safety

旧街凉风 提交于 2019-11-28 18:08:09
问题 I need to send some sensitive data over a Bluetooth Low Energy (BLE) data connection between a smartphone (iOS & Android) and an embedded device (CC2540 chip). Since I don't consider the app-code on the phones to be safe from hacking, I need to rely on BLE safety to get my encrypted package delivered from the server to the device once and once only (I must assume that any second attempt to deliver the package, must be from an attacker). I have been browsing the net a few days now, to find out

Can iOS do central and peripheral work on same app at same time?

让人想犯罪 __ 提交于 2019-11-28 17:59:03
Can iOS (iPhone or iPad) app have Core Bluetooth (BTLE) central manger and peripheral manager objects at same time? Can they operate asynchronously, or does main app thread need to make them share (switch back and forth). Sharing conceptual algorithm would be: disable peripheral manager, enable central manager and do central functions, and then, disable central mgr, enable peripheral mgr, and do peripheral functions (that is, send automatic nofications, and wait for and respond to remote characteristic commands), repeat... BACKGROUND GORY DETAILS: We have a local system with multiple iOS

Bluez: advertise service / gatt server example?

帅比萌擦擦* 提交于 2019-11-28 17:15:56
Goal I am developping a simple device running Linux. It is BLE capable, and I am currently using bluez 5.8. I want to trigger an action on this device using an iPhone. What already works: I can make the iPhone "see" the device. The iPhone also connects to the device. I setup the bluetooth device like this on linux (thanks to this question ): # activate bluetooth hciconfig hci0 up # set advertise data: "hello world" hcitool -i hci0 cmd 0x08 0x0008 48 45 4c 4c 4f 57 4f 52 4c 44 # start advertising as connectable hciconfig hci0 leadv 0 The iOS code is straightforward: - (int) scanForPeripherals {