Results 1 to 7 of 7

Thread: howto multiple sounds at once

  1. #1
    Join Date
    Oct 2004
    Location
    Netherlands
    Beans
    2,983
    Distro
    Ubuntu 8.04 Hardy Heron

    howto multiple sounds at once

    howto multiple sounds at once in Ubuntu Breezy (Gnome) including working sound in almost all games and system sounds.

    thnx to the user intangible and the wiki I was able to compile this howto.

    This guide is on your own risk(although there isn't much risk involved). I advise making backups of the files you edit. I'm posting this guide as a forum user and not as a staff member.

    If you don't have any sound at all you may need other modules to get your sound working properly. Please search for your (sound) chipset / motherboard in the video & sound section : http://ubuntuforums.org/forumdisplay.php?f=114 Also look at the links I give at the end of this post. If you still have problems after that please start a new thread in the video & sound section and at least post your $ lspci

    If you don't know what sound card or audio chipset you have do :

    Code:
    $ lspci
    and look for a line with a words like audio/multimedia/sound

    ac'97 : this esd guide works
    other chipsets/soundcards on which esd works : this esd guide will probably work
    other chipsets/soundcards on which esd doesn't work : try alsa
    audigy2 : try alsa (see below for more on audigy 2)

    This guide consists of three parts : oss,esd,alsa. Everyone do the oss part and do either the esd or the alsa part.

    Let's start with oss :

    intended audience : everyone

    First make sure ubuntu is installed properly:

    Code:
    $sudo apt-get install ubuntu-base ubuntu-desktop
    This will install alsa-oss. oss is needed for sound in a lot of games :

    Code:
    $sudo apt-get install alsa-oss
    You will probably need this module for oss :

    Code:
    $sudo modprobe snd_seq_oss
    If the modprobe didn't give an error make sure it gets loaded with each boot :

    Code:
    $ sudo pico /etc/modules
    and add this line :
    Code:
    snd_seq_oss
    OSS stuff (mostly games) will still tie up the sound card, but they don't run all the time. Just configure most things to use esound/esd and you'll be good.

    esd :

    intended audience : esd works but multiple sounds at once doesn't work properly. I tested this guide on a couple of machines. But for some soundcards / motherboards alsa is the better choice.

    Ubuntu uses a program called esd to allow multiple applications to access the sound card at one time. However, many third party applications not in Ubuntu main aren't designed to use esd to access the card. On some sound cards, this causes these applications to not produce sound. To work around this problem, esd must be configured to release the sound card when it is not using it. Place the following in your /etc/esound/esd.conf:

    Code:
    $sudo gedit /etc/esound/esd.conf
    and make it look like this :

    Code:
    [esd] 
    auto_spawn=0
    spawn_wait_ms=100
    default_options= -terminate -nobeeps -as 2
    Code:
    $sudo gedit /etc/libao.conf
    and make it look like this :

    Code:
    default_driver=esd
    Now go to system->preferences->sound
    -make sure system sounds are enabled
    -enable sound server startup
    -enable sounds for events
    -system bell > sound an audible bell

    safe all your open work. ctrl-alt-backspace to restart gdm.

    Try if everything works. If a program doesn't have sound make sure it uses esd/esound.

    You can try to "route" the sound of some program for example applicationx to esd using this command :
    $esddsp applicationx

    If you don't have multiple sounds (and it isn't an application which can't use esd which is blocking everything) try alsa.

    alsa :

    intended audience : esd doesn't work at all or the esd multiple sounds guide above didn't work (good enough)
    drawback : no system sounds

    Follow the instructions in this thread :
    http://www.ubuntuforums.org/showthread.php?t=44753

    You can try this if it doesn't work :

    Code:
    $sudo gedit /etc/esound/esd.conf
    and make it look like this :

    Code:
    [esd] 
    auto_spawn=0
    spawn_wait_ms=100
    default_options= -terminate -nobeeps -as 2
    audigy 2 :

    Do the OSS and ALSA part of the guide.

    Quote Originally Posted by wiki.ubuntu.com/DebuggingSoundProblems
    If you have ALSA set up with an Audigy 2 and everything "should" be working according to the manual, there is a chance that the following will fix it:

    Run 'alsamixer'. If you have multiple cards, run it for the appropriate card, like in my case 'alsamixer -c 1'

    Browse the channels until you find the "Analog/Digital Output Jack" and press 'M' to enable it if it's disabled
    some links :
    https://wiki.ubuntu.com/DebuggingSoundProblems
    http://www.ubuntuforums.org/showthread.php?t=44753
    https://wiki.ubuntu.com/SoundProblemsHoary
    Last edited by ubuntu_demon; January 3rd, 2006 at 12:40 AM.

  2. #2
    Join Date
    Oct 2004
    Beans
    Hidden!
    Distro
    Ubuntu Karmic Koala (testing)

    Re: howto multiple sounds at once

    I want to confirm that if you have an Audigy2, alsa is the better choice. I can run literally dozen of apps producing sound (although I normally don't... but to test), so I'm guessing it's using hardware mixing...

    Just grab alsa-oss and in multimedia selector set alsa as the out...
    The idea of copyright did not exist in ancient times, when authors frequently copied other authors at length in works of non-fiction. This practice was useful, and is the only way many authors' works have survived even in part. -- Richard Stallman

  3. #3
    Join Date
    Oct 2004
    Location
    Netherlands
    Beans
    2,983
    Distro
    Ubuntu 8.04 Hardy Heron

    Re: howto multiple sounds at once

    Quote Originally Posted by BoyOfDestiny
    I want to confirm that if you have an Audigy2, alsa is the better choice. I can run literally dozen of apps producing sound (although I normally don't... but to test), so I'm guessing it's using hardware mixing...

    Just grab alsa-oss and in multimedia selector set alsa as the out...
    thnx for the input!

  4. #4
    Join Date
    Nov 2005
    Location
    Cleveland, OH
    Beans
    116
    Distro
    Ubuntu Breezy 5.10

    Re: howto multiple sounds at once

    I myself have an Audigy 1.

    I want to use a program called TeamSpeak2RC2 (full duplex microphone prog for speaking with other people VOIP) and Enemy Territory (RtCW Engine Based Game) at the same time. TS if I recall is OSS. I have an ALSA wrapper installed from synaptic that allows my audigy to use TS properly using ALSA. How can I get them both making sound at the same time? I do have onboard sound, but if that's enabled I do not have the ability to use my sound wheel on my keyboard anymore (mundane thing to worry about but i use it a lot . . .)
    Steven Taylor
    http://itworksllc.net

  5. #5
    Join Date
    Oct 2004
    Location
    Netherlands
    Beans
    2,983
    Distro
    Ubuntu 8.04 Hardy Heron

    Re: howto multiple sounds at once

    Quote Originally Posted by lysis
    I myself have an Audigy 1.

    I want to use a program called TeamSpeak2RC2 (full duplex microphone prog for speaking with other people VOIP) and Enemy Territory (RtCW Engine Based Game) at the same time. TS if I recall is OSS. I have an ALSA wrapper installed from synaptic that allows my audigy to use TS properly using ALSA. How can I get them both making sound at the same time? I do have onboard sound, but if that's enabled I do not have the ability to use my sound wheel on my keyboard anymore (mundane thing to worry about but i use it a lot . . .)
    That's still an unsolved problem at least when doing it on one soundcard/sound chip. AFAIK currently the best way to solve it is to use one sound card/chip for enemy territory and the other one for VOIP. So in other words you might be able to use the audigy for ET and the sound chip for VOIP.

    Try searching on the forum for a more specific answer.
    Last edited by ubuntu_demon; December 13th, 2005 at 10:41 PM.

  6. #6
    Join Date
    May 2005
    Beans
    8

    Re: howto multiple sounds at once

    After trying various solutions to the "multiple sounds at once" problem I finally found what I feel is the best solution: jackd and with oss2jack. No other solution that I know of (including the ones provided in this thread) allow multiple oss apps to share sound simultaneously. As oss is still the defacto standard and many apps work only with oss (for example, Audacity), oss2jack and jackd is really your only solution if you don't want to have to be aware of what interface your app needs etc. I followed the directions for installing oss2jack here: http://fort.xdas.com/~kor/oss2jack/install.html. Going this route, your ALSA, JACK, and OSS apps all play with each other nicely simultaneously. You also get the benefits of low latency and professional flexibility with JACK.

    I recommend installing realtime-lsm for the low latency, and use qjackctl when first playing with JACK for tweaking.
    Last edited by whyameye; December 19th, 2005 at 05:58 AM.

  7. #7
    Join Date
    Oct 2004
    Location
    Netherlands
    Beans
    2,983
    Distro
    Ubuntu 8.04 Hardy Heron

    Re: howto multiple sounds at once

    Quote Originally Posted by whyameye
    After trying various solutions to the "multiple sounds at once" problem I finally found what I feel is the best solution: jackd and with oss2jack. No other solution that I know of (including the ones provided in this thread) allow multiple oss apps to share sound simultaneously. As oss is still the defacto standard and many apps work only with oss (for example, Audacity), oss2jack and jackd is really your only solution if you don't want to have to be aware of what interface your app needs etc. I followed the directions for installing oss2jack here: http://fort.xdas.com/~kor/oss2jack/install.html. Going this route, your ALSA, JACK, and OSS apps all play with each other nicely simultaneously. You also get the benefits of low latency and professional flexibility with JACK.

    I recommend installing realtime-lsm for the low latency, and use qjackctl when first playing with JACK for tweaking.
    thnx for the info!

    I'll look into it when I have time. Multiple oss applications doesn't happen very often but it happens (primarily with games).

    Have you tried combining the howto from this thread with the oss2jack howto ? Since not every application is able to use oss.

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •