How do I test iOS microphone use on the simulator?

The built in microphones should work with the iOS Simulator.


I don't think microphone works as of iOS 8.2. Here is link from Apple documentation that state this fact: https://developer.apple.com/library/ios/documentation/IDEs/Conceptual/iOS_Simulator_Guide/TestingontheiOSSimulator/TestingontheiOSSimulator.html

Look at the Hardware limitations section.


The simulator this will automatically use your Mac's built-in microphone

AVAudioRecorder will record audio from the microphone. If you're using the simulator this will automatically use your Mac's built-in microphone, so you can test either on device or in the simulator.

And if you are on a Mac mini without a microphone input?

Remember that there is a neat trick to record audio from your iPhone/iPad. You need a lightning cable or USB-C cable connected and enable your hardware device in the Utilities/Audio Devices settings:

Audio Devices settings

Click on enable: enable

This new audio input will be visible in your emulator! So now you can record in simulator even if your Mac hasn't got a microphone

It has been available forever I believe and I just verified, it works for the Mac mini 2018 and macOS Catalina 10.15.4 and Xcode Version 11.4.1.

It will be enough to trouble shoot your iOS apps, but there is a small caveat. By default you get the line out from your iOS device, so I could play music and my mac would receive it. So far so good.

However to properly access the mic you would need a third party app to bridge and make the mic available to the mini but this is not necessary to just troubleshoot the mic on the simulator. I hope I explained myself.