Reputation: 267
I have an issue where the microphone on my 6s will only give me an output if I am right in front of the microphone. I'd like to change the sensitivity so that it will read a frequency even from a couple of feet distance.
This is how I initialize the AKMicrophone:
AKSettings.audioInputEnabled = true
mic = AKMicrophone()
tracker = AKFrequencyTracker.init(mic)
silence = AKBooster(tracker, gain: 0)
Upvotes: 4
Views: 461
Reputation: 4573
Try sticking a booster before the tracker:
mic = AKMicrophone()
boostedMic = AKBooster(mic, gain: 5)
tracker = AKFrequencyTracker.init(boostedMic)
silence = AKBooster(tracker, gain: 0)
Adjust the constant "5" accordingly. HTH!
Upvotes: 5