Hello, I have been searching for some time and I can't find a detailled tutorial on how to easily record and then read audio on the emulator under eclipse. I have found these steps:
- You have to install a virtual sd card with mksdcard.exe 1024M sdimg.iso -then run the emulator : emulator.exe -sdcard sdimg.iso //where sdimg.iso it is the path to the sdcard -then run adb.exe : adb push local_file sdcard/remote_file -then you should put : <uses-permission android:name="android.permission.RECORD_AUDIO"></uses-permission> in the androidmanifest.xml -then there is some code to implement which should look like : private void startRecord() { recorder = new MediaRecorder(); recorder.setAudioSource(MediaRecorder.AudioSource.MIC); //ok so I say audio source is the microphone, is it windows/linux microphone on the emulator? recorder.setOutputFormat(MediaRecorder.OutputFormat.THREE_GPP); recorder.setAudioEncoder(MediaRecorder.AudioEncoder.AMR_NB); recorder.setOutputFile("/sdcard/test.3gpp"); recorder.prepare(); recorder.start(); } -then you should stop with : recorder.stop(); // at some point (I have no idea when and where to decide to stop but I haven't searched yet) -then you should play it. I have also heard about : http://code.google.com/intl/fr/android/reference/emulator.html#sdcard in this page of the manual (~1/4 of the total scroll), there are some informations about "Emulator Startup Options", one of them is about Media -audio <backend> I couldn't find much about that backend thing, google didn't said much about it. I still don't know if it's important to the audio recording process. The fact is all these steps are pretty blurry to me, and I believe I am not the only android newbie trying to record some sound :) Anyone knows where we can find a complete tutorial "for dummies" teaching this feature? Any help is of course greatly appreciated Thanks. On 27 jan, 20:08, Breno <breno.min...@gmail.com> wrote: > Hey Andrei, > > To recordaudioit's pretty easy. But, you must record in > sdcard, only. Be sure your path to file it's pointing to sdcard, and > you have one mounted in eclipse (or something else). It's working > perfectly. > > Regards > > Breno > > On Jan 15, 8:58 am, "Andrei Craciun" <avcrac...@gmail.com> wrote: > > > Thanks David... > > > 2009/1/15 David Turner <di...@android.com> > > > > the emulator now supportsaudiorecording. If you have problems with it, > > > you should report mode detailed information about it here > > > > On Thu, Jan 15, 2009 at 11:05 AM, Andrei Craciun > > > <avcrac...@gmail.com>wrote: > > > >> Hi All, > > >> As reported on this blog: > > >>http://blog.roychowdhury.org/2008/04/29/sip-ua-for-android-stack-rtp-...some > > >> problems inrecordingaudioon the emulator, but everything > > >> works fine on the real phone. Does anyone has a workaround forrecording > > >>audioon the emulator? > > > >> Thanks in advance, > > >> A. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~----------~----~----~----~------~----~------~--~---