Is there an option to connect headphones to the phone with SFSpeechRecognizer enabled?
I am trying to build an application. in that mono will use a speech recognizer for text with the headphones turned on.
I have gone through a lot of links about problems with connecting headphones to the phone due to AVAudioeSession configurations, and it seems that I have tried everything
This is how my configs are
let audioSession = AVAudioSession.sharedInstance()
audioSession.setCategory(.playAndRecord, mode: .videoChat, options: [.allowBluetoothA2DP, .defaultToSpeaker])
try audioSession.setActive(true)
I found a small preset description for the type here: documentation
Bluetooth is already known and present in options and much more, but we managed to connect sound through airpods
In fact, I would like the sound to be redirected to the airpods