Hi, I am trying to do similar things here. I want to build a keyboard that record audio and then process with Whisper API to get more robust dication. My keyboard extension works fine on simulator. but when i try to run it on real device. I always get Error Domain=NSOSStatusErrorDomain Code=561015905 "Session activation failed" UserInfo={NSLocalizedDescription=Session activation failed} when i do
private var audioRecorder: AVAudioRecorder?
private var audioSession = AVAudioSession.sharedInstance()
try audioSession.setCategory(.playAndRecord, mode: .default, options: [.allowBluetooth])
try audioSession.setActive(true)
Topic:
App & System Services
SubTopic:
Hardware
Tags: