Enabling audio in emulator

by PAS » Tue, 07 Oct 2008 08:14:17 GMT

Sponsored Links
 Since I found nothing about this while looking, I thought I would
document my findings here.

I had some trouble getting audio to work in the Android emulator.
Eclipse was displaying the following:
    [2008-10-06 16:18:12 - Emulator] emulator: warning: opening audio
output failed

Having a look at the emulator startup options for Android 1.0 SDK,
Release 1:
     http://code.google.com/android/reference/emulator.html #startup-options

...I found some of the Media ones are not correct . Even the self
documentation inside emulator -help-audio is not correct:
    $ emulator -useaudio
    invalid command-line parameter: -useaudio
    $ emulator -help-audio-out
    unknown option: -audio-out
    $ emulator -help-audio-in
    unknown option: -audio-in

I tried the obvious, but got the same error I was getting through
Eclipse (I guess alsa is the default)
    $ emulator -audio alsa
    emulator: warning: opening audio output failed

The only way I got sound working was to run:
    $ emulator -audio oss

Please note that while the emulator is running, you will not be able
to use other audio apps (at least I couldn't).

I hope that helps someone out there. If I have missed something,
please let me know.


Enabling audio in emulator

by GUS » Tue, 07 Oct 2008 09:32:00 GMT

 Nice. But I think your audio doesnt work normaly becouse some other
program on your machine is blocking the audio devices. Fortunatelly,
my audio works fine.

Thx anyway.


Sponsored Links

Enabling audio in emulator

by Selmi » Thu, 30 Oct 2008 07:03:04 GMT

 i had same problem, but when i used lsof to find out what is
accessing /dev/snd i found that nothing does..so i don't know what
could block soundcard
emulator -audio oss fixed problem for me

also i found that if i have rhytmbox  playing and i close emulator it
kills sound and make rhytmbox freeze. i would guess that emulator acts
very aggresive with sound


Other Threads

1. Need Official HOW-TO: Upgrade from Original ADP1 firmware to RC33

The announcement of Android 1.1 has been made, and I am eager to move

However I believe my Android Dev Phone 1 has an older version (than
RC30) on it when it arrived and the upgrade fails when I use the
upgrade to RC33-from-RC30 zip file.

Fortunately the upgrade rolls back and leaves the phone fully
operable. So I can keep working with v1.0_r2

Here's some info:

  Firmware version:  1.0
  Baseband version:
  Build number:        dream_devphone-userdebug 1.0 UNLOCKED 116222

I'd like to ask the Android team to take the time to gather the the
information and zip files to enable someone to upgrade their ADP1s
from the version delivered with the phone all the way to RC33 and post
the zips and an "official" HOW-TO so some of us can catch up.

As a model I'd like to suggest the many linux sites (Ubuntu comes to
mind) that post various versions of their software along with
information on the proper upgrade path to get from early versions to
the current one. Once the first official definitive HOW-TO is built it
is much easier to add information for other upgrades to come.

Even with the short time I've been working with it, I am truly amazed
at all the stuff packed into the G-1 and the android system. I'm
really impressed, and I have a lot of ideas, but I need some help to
catch up with the group. I am sure there are other folks joining
development now that could use similar help.

Thanks,   JLMG


2. Easy Eclipse Help?

Hello all,
When I type in eclipse, lets say,

EditTextPreference passwordPref = new EditTextPreference(this);

After I put the "." after "passwordPref", I want there to be a list
for me to choose what options I have to put there. I know this is
possible because a while ago it did work, but now for some reason it


3. Regarding installation of application in memory card in G1

4. Scroling in ListView

5. Applicatiom Image Location

6. Device Interface to Android Phone

7. How to get an interface on a service without destroying the service at unbind