IOBluetooth

RSS for tag

Gain user-space access to Bluetooth devices using IOBluetooth.

Posts under IOBluetooth tag

31 Posts
Sort by:

Post

Replies

Boosts

Views

Activity

Bluetooth driver crashes on IOS 18.2.1 (22C161)
I have been trying to investigate some of the kernel crashes I have noticed on my IOS crash logs. Some of these are in device driver software for the peripheral interfaces. Given that the driver code executes with kernel privileges, these kind of crashes leave the device vulnerable to remote code injection, with no user interaction required in some cases. Crash Report from IOS 18.2.1 If Apple can provide the symbol table for IOS 18.2.1 blue tooth driver and source code, I can gladly help investigate this further.
1
0
91
7h
Possible to allow x code builds to run background processes for over 3 minutes
I have an app that I'm using for my own purposes and is not in the app store. I would like to run an http server in the background for more than the allotted 3 minutes to allow persistent communications with a connected Bluetooth device. The Bluetooth device would poll the service at intervals. Is this possible to do? This app does not need app store approval since it's only for personal use.
2
0
121
1w
iOS 18.1-18.3 Bluetooth is not working (infinity restarting)
The Bluetooth on my iPhone 14 hasn’t been working for a week now. Everything was fine until, at some point, it started endlessly turning on and off by itself. I’ve tried resetting the settings, doing a hard reset, updating to iOS 18.3—none of these helped. I even deleted all VPN profiles just in case (I saw this suggested on forums), but that didn’t work either. According to forums, this bug has existed since September and affects thousands of people. The constant cycling causes the Bluetooth settings to freeze. Please help! My watch, headphones, car—everything has turned into a pumpkin!
0
0
432
3w
BLE iOS in background (app collapsed)
Hello. In my app, I need to implement the following mechanism: I need to collect data from nearby Bluetooth devices, process them, and send this information to the server at short intervals, including when the app is minimized. Is this possible on iOS? BGProcessingTask has restrictions related to battery saving policies and does not guarantee task execution at specific intervals. Additionally, there is a limitation on background task execution, which can occur no more frequently than every 15 minutes. However, some apps, such as Google Maps, work in the background and update geolocation data. Could you suggest a solution for this task? Thanks for any help on this topic
2
0
204
3w
Does BLE Peripheral work in background on iOS?
Hello, I am working on a Flutter application where I need to use Bluetooth Low Energy (BLE) in Peripheral mode to advertise data even when the app is in the background (or when the screen is turned off) on iOS devices. I am using the package flutter_ble_peripheral to handle BLE advertising and peripherals. My goal is to make sure that the BLE advertising continues running when the app is minimized or in the background. Here is what I have already done: Added the required Bluetooth permissions in Info.plist. Enabled Background Modes in Xcode (with Bluetooth LE Accessories enabled). Used the FlutterBlePeripheral.start() method to start advertising. However, when I minimize the app or turn off the screen, the BLE advertising seems to stop. I have ensured that the app is not terminated but still the advertising is not persistent. I would like to confirm whether flutter_ble_peripheral works reliably in the background on iOS, or if there are any additional configurations or limitations I need to consider to ensure that advertising continues in the background. Any insights or experiences would be greatly appreciated. Thanks!
1
0
243
Jan ’25
Unable to connect app via bluetooth in iOS
[ERROR:flutter/runtime/dart_vm_initializer.cc(41)] Unhandled Exception: PlatformException(reactive_ble_mobile.Central.(unknown context at $1013cc3b4).Failure:1, The operation couldn’t be completed. (reactive_ble_mobile.Central.(unknown context at $1013cc3b4).Failure error 1.), {}, null) #0 StandardMethodCodec.decodeEnvelope (package:flutter/src/services/message_codecs.dart:648:7) #1 MethodChannel._invokeMethod (package:flutter/src/services/platform_channel.dart:334:18) #2 ReactiveBleMobilePlatform.discoverServices. (package:reactive_ble_mobile/src/reactive_ble_mobile_platform.dart:290:15) #3 BleDeviceInteractor.discoverServices (package:ssss/pages/src/ble/ble_device_interactor.dart:47:22) #4 _DeviceInteractionTabState.discoverServices (package:ssss/pages/machines/satellite/device_interaction_tab.dart:283:20)
1
0
234
Jan ’25
The latest IOS doesn't act for the custom iBeacon anymore.
I have some questions about the changes that the latest IOS doesn't act (scanning or monitoring) for our custom beacon devices. Since about 2015, We has provided some 'location based service' by using our custom iBeacon devices. However We've just realized that the latest IOS devices doesn't work with our custom iBeacon devices. but also realized It could still work with the other normal iBeacon devices. So, I've dig this issues for a while and finally I got the answer. It's because the one byte of Ibeacon advertsing packet payload. the followings are the differences about manufacturer data part between a normal Ibeacon and our custom beacon. normal Ibeacon 0xFF 0x4C00 0x02 0x15 0x736E75685F70656F706C655F74656331 0xEA61 0x03EB 0xC5 our custom Ibeacon 0xFF 0x4C00 0x02 0x15 0x736E75685F70656F706C655F74656331 0xEA61 0x03EB 0xC5 0xDA Yes, I know. after many of searches and research, Now I've understood the byte (meaning the length of following payload) should be changed as '0x16'. But It is certainly something that has worked well not so long ago. Anyway, The introduction was so long, but this is the one question what I'd like to ask about. I need to know exactly which version of IOS this change came from. (I've tried but I couldn't find any thing about this on the official documents.) I need to expaing to my customers what's going on. for that, I need the information that exactly which version of IOS It didn't work from. Thanks in advance. Regards.
1
0
248
Jan ’25
Problem with deleting SDP service (macOS, IOBluetooth)
Hello everyone. macOS, IOBluetooth framework. My goal is to create a temporary SDP service. According to the documentation, by default a temporary service is created (aka Persistent = NO), which is deleted after the application is closed. The documentation also mentions the IOBluetoothRemoveServiceWithRecordHandle function for forced removal of the service. This function is deprecated and is currently unavailable. I guesse that it has been replaced by the IOBluetoothSDPServiceRecord.removeServiceRecord method. The essence of the problem is that the server is not deleted either using removeServiceRecord or even after app closing. That is, if you create several services and try to delete them, they will remain alive. Only turning Bluetooth off and on in the OS helps. I tested all versions of macOS starting with Monteray. The same behavior. for (int i = 0; i < 10; i++) { service = [IOBluetoothSDPServiceRecord publishedServiceRecordWithDictionary:dictionary]; if (!service) { NSLog(@"Failed to create service"); } else { [service getRFCOMMChannelID:&channelID]; [service getServiceRecordHandle:&serverHandle]; NSLog(@"A new service has been created handle=%u, channelID=%hhu", serverHandle, channelID); if (service.removeServiceRecord != kIOReturnSuccess) { NSLog(@"Failed to delete service"); } //service.release; service = nil; } } Can someone confirm this behavior? And is there a solution? A minimal test example is available at the link
1
1
432
Dec ’24
iPad - Bluetooth Peripheral MTU No More Than 20 Bytes
All, Thanks in advance! I'm having a very hard time increasing the MTU to any value beyond 20. The research I've done states iOS 16.1 and beyond supports up to 512 bytes. Yet, the peripheral device will only read 20 bytes. It's to be noted that I'm using Expo SDK 51 Bare Workflow, and the react-native-ble-plx library. I have the app functioning as both Central and Peripheral on iOS 18.1 devices, and data is successfully being written and read to the characteristic. Because the Expo app is Bare Workflow, I'm able to make any configurations via Xcode, and if there is any patches needed to the react-native-ble-plx library, we have the architecture to support that too. I wanted to provide that context before being recommended to go to the Expo forums (which I have/will be). I also added the CoreBluetooth framework to the project in hopes that would overwrite the react-native-ble-plx imports, but I noticed react-native-ble-plx uses Swift while CoreBluetooth is Objective-C. Looking forward to your responses!
1
0
367
Jan ’25
BLE Requirements for MacOS
I am working on a hobby project to develop my own Bluetooth peripheral. The platform for this peripheral is a Espressif ESP32-based TinyS3 from Unexpected Maker. I have defined the bluetooth device & service information using custom UUIDs. Using nRF Connect or Light Blue mobile applications I can discover and connect to my device. I receive confirmation of this BLE connection and modifications to the my BLE Service from my code on my TinyS3. I am attempting to write a custom software program that uses the onboard Mac Bluetooth hardware to detect this device. I am technically using Qt's Bluetooth infrastructure via PySide6 [python]. Despite being able to see my device in the mobile BLE applications, my software as well as the Mac Bluetooth System Services does not detect my BLE device. I am broadcasting advertising messages at a 250ms rate, and since they are findable by these mobile applications, I am wondering if MacOS has specific requirements for advertising data for what it considers as a "legitimate/ connectable" device. Any help would be greatly appreciated. Thank you!
1
0
359
Dec ’24
How to update a Bluetooth device's name on iPhone Settings list after a rename via an App
Hello, Our device firmware has a companion iOS app that allows a user to rename it. We are connected to the iPhone via BT Classic. The new name is reflected on the app, however, the iPhone BT device list still shows the old name. It doesn't seem to get updated to the new name unless we unpair/re-pair the device to the phone. Is there a way to get the iPhone to update to the new name in the Settings BT device list without unpairing the device? Is this possible in BT Classic? Thanks.
1
0
356
Dec ’24
Bluetooth HID Button Release Not Working on iPad for Bluetooth Pointer
I am developing a Bluetooth pointer device to control an iPad using HID. Most functionality works well, including mouse movement and button presses. However, I am encountering a strange issue with button releases. For the HID descriptor for the iPad I defined the following: 0501 0902 A101 8503 0509 // Mouse Buttons 1901 2902 // 2 buttons 1500 2501 9502 // Report count for two buttons 7501 8102 9501 7506 // Padding 8103 0501 0901 A100 1500 // Min value 26FF7F // Max value (0...32767) 0930 0931 7510 9502 8102 // Absolute coordinate pointer C0 Do you see an issue with the descriptor? Example packages sent over bluetooth: 0xA103 01 4F3A FB50 // 01 is a left button click, works well, an icon is clicked on iPad. 0xA103 00 4F3A FB50 // 00 should be a left button release, package is sent and received, but button is NOT released, but held on the iPad! The mouse coordinates are updated well, however, I expect the button to be released when sending 0xA103 00 4F3A FB50, but it is held down instead. Perhaps there is a special requirement for iOS to make this work? It is close to be fully functioning.
0
0
308
Dec ’24
iOS Bluetooth Reconnect
Hello Apple, I am a Bluetooth peripheral developer. Recently, I encountered the following issue while developing a Bluetooth smartwatch on iOS: I have a Bluetooth smartwatch that supports CTKD connections. After pairing and connecting with an iOS device, notifications from iOS can be sent to the watch normally. However, after a few days, I noticed that my watch stopped receiving any iOS notifications. Upon checking my phone's Bluetooth settings, I found that the watch's Bluetooth connection on the phone system had disconnected and did not automatically reconnect. After manually reconnecting, I observed that only the BT (classic Bluetooth) connection was established, while the BLE (Bluetooth Low Energy) connection remained disconnected. I would like to understand what could be causing this issue and how to resolve the problem of Bluetooth reconnection.
1
0
327
Dec ’24
Is it possible for CarPlay to establish a connection with a Bluetooth Low Energy (BLE) dongle when the phone app is fully closed or not running in the background?
I’m currently developing an app that communicates with a BLE dongle. When I swipe up to close the app on my phone, both the phone app and the CarPlay app are terminated. From the CarPlay interface, I can relaunch the app. My question is: Can CarPlay establish a connection with a BLE dongle when the phone app is fully closed or not running in the background?
3
1
503
Oct ’24
Bluetooth pairing problems (iPhone 16 Pro with Sony WH-1000XM5)
Upgraded from an iPhone 13 Pro Max to an iPhone 16 Pro a week ago. Both running on latest iOS 18 and data transfer was done manually Bluetooth pairing seems to be facing a problem. I have been trying to pair up with my Sony WH-1000XM5 but somehow the phone fails to detect the headphones on Bluetooth. Today I tested with my spare earbuds Bose Soundsport Wireless and faced exactly the same problem. Strange Carplay and my home JVC home player don‘t have this problem
3
1
2.1k
Oct ’24
CBATTErrorRequestNotSupported while transferring data between Bluetooth LE devices
I am trying to implement BLE communication between installations of an iOS app and I am following Transferring Data Between Bluetooth Low Energy Devices since the data I need to transfer exceeds the 512 byte limit for attribute values. I already have this working based on an older version of the app, however after I integrated with the mainline of development I am getting CBATTErrorRequestNotSupported which seems to be caused by OSStatus 65535 (which is kBluetoothSDPErrorCodeReservedEnd, but that is documented to not even be present on iOS). So it seems that a change on our end is causing these errors, but I am completely stumped as to what change that might be. Is anyone able to enlighten me?
2
0
554
Aug ’24