Home > other >  On Microphone permission in iOS 16 producing screeching noise
On Microphone permission in iOS 16 producing screeching noise

Time:11-10

I am working on a guitar application written in Objective-C. It has a feature like Tuning from Guitar. The tuning screen requires microphone permission. When we give permission to the app, suddenly the app starts producing a screeching noise which sounds very weird.

The same code is working on iOS 15 and lower versions. Only in iOS 16 and higher it is having this noise issue.

I have used audiokit and the version of audiokit is 2.2 and the latest version is 5.5.7

pod 'AudioKit'

CodePudding user response:

The screeching noise is because there is a feedback loop between your microphone and speaker. You could set the AVAudioSession.Category to .record which would silence the playback audio. If you need to use a .playAndRecord session then you need to make sure the output node for your AVAudioSession instance is silent.

CodePudding user response:

There are a few examples in the AudioKit Cookbook that show how to access the mic muted in AudioKit 5. https://github.com/AudioKit/Cookbook/blob/main/Cookbook/CookbookCommon/Sources/CookbookCommon/Recipes/MiniApps/Recorder.swift

  • Related