Hi I'm adding Bluetooth functionality to my app.
I've set audio session category to AVAudioSessionCategoryPlayAndRecord
and give options AVAudioSessionCategoryOptionMixWithOthers and AVAudioSessionCategoryOptionAllowBluetooth, and AVAudioSessionCategoryOptionAllowBluetoothA2DP.
And when I got AVAudioSessionRouteChangeNotification, currentRoute value was changed to BluetoothHFP automatically.
Is this by design?
If it is, how can I rollback BluetoothHFP route to orignal one(BluetoothA2DP)?
I tried to use setPreferredInput to 'Built-In Microphone' but setPreferredInput changed output route to 'Reciever' too.