Hi, Team.
We are currently creating a VoIP calling app using pjsip and want to be able to end a call using the headset button while the app is in the middle of a call (AVAudioSession.category == .playAndRecord), but MPRemoteCommand does not receive any events.
After trying various things, We found that the button will respond if the audio output destination is set to the speaker or if .allowBluetoothA2DP is set as an option, but this is not suitable for this use case because audio input and output would be from the device rather than the headset.
=================================================
Problem
Headset button events cannot be received from MPRemoteCommand during a call.
What is expected to happen?
When the headset button is pressed during a call, a handler registered in some MPRemoteCommand is called back.
What does actually happen?
No MPRemoteCommand responds when the headset button is pressed during a call.
Information
Sample code
Echoes back the audio input with a 5-second delay to simulate a phone call.
https://github.com/ryu-akaike/HeadsetTalkTest-iOS/
Versions
macOS: Sonoma 14.5
Xcode: 15.3
iPhone: 11
iOS: 17.5.1
=================================================
Thank you.
Ryu Akaike
IOBluetooth
RSS for tagGain user-space access to Bluetooth devices using IOBluetooth.
Posts under IOBluetooth tag
30 Posts
Sort by:
Post
Replies
Boosts
Views
Activity
Are there any cases where when connected to a specific Bluetooth device on an iPhone or iPad, the Bluetooth device connected at the same time is frequently disconnected or the app connected via CoreBluetooth is disconnected?
Our app connects to an iPhone or iPad and connects to CoreBluetooth API to perform specific functions or operations.
When a JBL Bluetooth speaker is connected, the connection is automatically disconnected during operation.
When the JBL Bluetooth speaker is disconnected, the Bluetooth connection between our apps is not disconnected.
It does not happen on all iPhones or iPads, but it seems to happen on some devices.
Our app users are experiencing this issue with JBL Bluetooth speakers. So we are trying to replicate this phenomenon with our Bluetooth speaker, but it doesn't work.
Has anyone else experienced something similar?
I am wondering if this phenomenon can occur.
Xcode 15.3
macOS Sonoma 14.5
I'm trying to build an app for macOS that will emulate a HID device (keyboard, mouse, game controller) and send those inputs to an IOS device over Bluetooth. I've figured out how to map the inputs from the relevant documentation (Human Interface Device Profile 1.1, Apple Accessory Design Guidelines) but I can't seem to get the Bluetooth services working.
I've found an example of how to implement the Bluetooth service (from macOS Mojave but updated to Swift 5). The code will build without issue and asks for the necessary permissions in settings. After giving permissions and rebuilding, the peripheral simply does not appear on the iPhone Bluetooth settings menu (or the Bluetooth settings menu of any device).
I suppose the question I'm asking here is if macOS Sonoma prevents the macOS device from advertising as a keyboard peripheral. Furthermore, is there any documentation that describes these limitations.
Here is the full example code (too large to post):
https://github.com/MonoidMusician/Bluetooth-Keyboard-Emulator/blob/master/Keyboard%20Connect%20Open%20Source/BTKeyboard.swift
Hello,
I'm building apps for iPhone and iPad.
Those are working together like a 2-screen Nintendo switch.
Is there any way for communication between iPhone and iPad without an outside server?
PAN(personal area network) could be a solution, but I could not find any information to use it for my case.
If the iPad is connected to iPhone as a personal hotspot (though there's no cell tower), they should be communicate each other. I think there's a better way for my case.
Could anyone can tell me where I start to looking for?
Thanks,
JJ
We have observed a significant increase in download time from the sensors to the mobile device after recent OS updates. We are connected to the external sensors via the BLE interface using the following connection
parameters(15,15,0,6000)
https://mbientlab.com/tutorials/MetaMotionRL.html:
example 1.For 1 Meter with duration of 28 Seconds the IOS 17.1 taking 44 secs where as IOS 17.5.1 taking 82 secs .
2..For 1 Meter with duration of 45 Seconds the IOS 17.1 taking 74 secs where as IOS 17.5.1 taking 143 secs .
Even with the same connection parameters, download times were considerably lower in iOS 15 and below devices.
We are currently using the connection parameters 15, 15, 0, 6000.
I have learned from some documents that the minimum connection interval was changed to 20, but when I tried it, the download time increased further. I am seeking assistance on how to achieve the same download times as the older versions.
https://mbientlab.com/community/discussion/comment/11852#Comment_11852
Hi guys,
I observed the infinite connection callback(inSelector) for some Bluetooth devices (such as an iPhone SE or Mac Mini) even when I powered off them. However, the issue is not reproducible easily.
(IOBluetoothUserNotification *)registerForConnectNotifications:(id)observer
selector:(SEL)inSelector
ble.txt
Looks like there are many -[CBManager xpcConnectionDidReceiveMsg:args:] calls when the issue occurs based on the sample, so it might be caused by the XPC connection with bluetoothd?
Has anyone else experienced this issue, or any workaround for it? such as should I restart the bluetoothd?
Hi!
I am trying to figure out whether there are any ways to get notifications when a macOS user connects to another device via Bluetooth (specifically when a smartphone is paired with a MacBook). I know about IOBluetooth, but it seems like you have to send periodic queries for devices when using this framework, and there is no general way to receive such notifications.
I know that IOHIDManager may help to track connection with human interface devices such as keyboards, trackpads, joysticks, etc. But is there any API in IOKit/DriverKit that could help get notifications when a macOS user connects to a smartphone?
Maybe I am missing an important part of IOBluetooth, so I would appreciate any help.
Why is BLE easily disconnected after pairing in cellular networks on iOS 17.3.1, and this situation does not occur in WLAN
Hi!
I have previously developed an app that established a Bluetooth connection between two devices (two iPads). Now, I want to port the client-side app to VisionPro. Similar to the iPad app, I have supplemented my info.plist file with the following line:
NSBluetoothAlwaysUsageDescription
Uses BLE to communicate with devices.
Despite this, when I launch the app on VisionPro, the prompt to use Bluetooth does not appear. What could be the issue? What additional settings do I need to configure to enable Bluetooth usage?
Hello
Our app has been rejected from the app store because of 1.4 Physical Harm https://developer.apple.com/app-store/review/guidelines/#safety
This app is used by the users from Kenya (Only registered users). Users can log their health based self-assessment data like blood pressure, glucose level, temperature, body weight, BMI with medical hardware devices and that will be shared with specialist (Physician or Clinical) to do the diagnosis and advice subscription accordingly.
Problem:
We have the above features from earlier versions but with the new version update our app got rejected from app store stated that we have violated the app stores' guidelines (1.4.1 Physical Harm - Safety)
Your app connects to external medical hardware to provide medical services. However, to be compliant with App Store Review Guideline 1.4.1, you must:
Provide documentation from the appropriate regulatory organization demonstrating regulatory clearance for the medical hardware used by your app
Provide documentation of a report or peer-reviewed study that demonstrates your app’s use of medical hardware works as described
Our app's features:
AccuCheck-Instant Glucometer: CE0088 This product fulfils the requirements of the European Directive 98/79/EC on in vitro diagnostic medical devices.
b) FORA-DigitalThermometer-IR21b: CE Mark for compliance with European Directive integration over Bluetooth
c) FORA-OximeterPO200: CE0123 and IEC 61000-4-3 Compliant integration over Bluetooth
d) FORA-Weighing Machine-W310b: IEC/EN 61010-1, IEC/EN 61326, EN 301 489-17, EN 300 328 Compliant integration over Bluetooth
e) OmronBPMachine-HEM -9210T: EC & EN Compliance integration over Bluetooth
Please anyone help us to resolve this issue.