title: Using microphone in android emulator (Java + Android beginner)
body: <p><a href="https://stackoverflow.com/questions/5254994/can-the-android-emulator-record-and-play-back-audio-using-pc-hardware">I READ HERE</a> that using microphone might be possible in android emulator so I decided to try it out (Although an answer to <a href="https://stackoverflow.com/questions/5924190/how-do-you-enable-a-microphone-input-in-the-android-emulator">THIS QUESTION</a> says it's not possible)<br>
  I copy/pasted the code provided in the <a href="http://developer.android.com/guide/topics/media/audio-capture.html" rel="nofollow noreferrer">ANDROID DEVELOPERS WEBSITE</a> and added   </p>
  
  <pre><code> &lt;uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" /&gt;
   &lt;uses-permission android:name="android.permission.RECORD_AUDIO" /&gt;
  </code></pre>
  
  <p>to the manifest as well. The interface shows up, with two command buttons, one for start recording and one for play recording. The text on the start recording button changes to stop recording once I press it, but if I press on the stop recording button, the application sort of hangs and then crashes (<code>Unfortunately, Mic Rec Test has stopped.</code>). The logcat then gives out this message  </p>
  
  <pre><code>E/AudioFlinger(   40): Error reading audio input
  
  E/AudioFlinger(   40): Error reading audio input
  
  E/AudioFlinger(   40): Error reading audio input
  
  E/AudioFlinger(   40): Error reading audio input
  
  E/AudioFlinger(   40): Error reading audio input
  
  E/AudioFlinger(   40): Error reading audio input
  
  E/AudioFlinger(   40): Error reading audio input
  
  E/AudioFlinger(   40): Error reading audio input
  
  E/AudioFlinger(   40): Error reading audio input
  
  E/AudioFlinger(   40): Error reading audio input
  
  E/AudioFlinger(   40): Error reading audio input
  </code></pre>
  
  <p>over and over and over again. In fact, it's still doing it as I am writing this question. What does this mean, and why did the program crash when I clicked stop recording?  </p>
  
  <p>---EDIT---<br>
  I just checked the emulated virtual device detail properties by clicking on the <code>Details...</code> button in the AVD Manager and in the AVD details box, I can see that <code>hw.audioInput</code> is set to <code>Yes</code>. This means recording audio from emulator should be possible shouldn't it?  </p>
  
  <p>--- EDIT 2 ---<br>
  <a href="https://stackoverflow.com/questions/5472370/why-is-it-impossible-to-use-the-speech-recorder-on-the-android-emulator">Why is it impossible to use the Speech Recorder on the Android emulator?</a>  </p>
  
  <p>I saw that the emulator comes with a built in speech recorder app, but the problem is still the same, the moment I click on <code>record</code>, it crashes. That's fair enough, but Why have the speech recorder app in the emulator if the emulator is not supposed to work with sound input? Or am I missing something here, and it is in fact possible to get the sound recorder working?</p>