View RSS Feed

oldcpu's meandering thoughts on Computers, GNU/Linux and openSUSE

Pulseaudio Basics for openSUSE with pavucontrol

Rating: 2 votes, 4.50 average.
by , 07-Jan-2012 at 11:31 (9791 Views)
This is a basic tutorial on pulseaudio tuning using pavucontrol (pulse audio volume control application).

Pulseaudio basics appear to stump many users. Even long-in-the-tooth GNU/Linux users struggle with pulse, as they find the transition from the known alsamixer/kmix with text .asoundrc files to the very simplistic pulse audio a new experience that they are not prepared to adjust to. In the early days of pulseaudio, it was buggy, which complicated its acceptance.

I deferred moving to pulse for a long time, but when I did, I realized it was powerful and yet simple to use, as long as one opened the correct gui / applications. And while it is still not bug free today, it is significantly improved and provides capabilities that were previously only available by using jack, or by complex .asoundrc file codeings where one needed to speak binary to understand what was happening.

This blog entry is NOT intended to solve pulseaudio problems for those who have scratchy sound, or sound that is stuttering, or playback/recording is too fast. For those users I recommend you surf the web and find a troubleshooting guide, such as Troubleshooting pulse audio problems

The application 'pavucontrol' (pulse audio volume control) is installed by default in Gnome, but it needs to be separately installed in KDE, from the official openSUSE OSS repository (which is aleady automatically setup on every openSUSE install). I am using openSUSE-11.4 for this blog entry, but openSUSE-12.1 is pretty much identical in these basics.

This blog entry will consist of a series of posts using my 11 year old Sandbox PC (which has integrated mother board sound and also a second sound device which is an ancient sound blaster compatible PCI card).

May I also point out an excellent blog entry of jdmcdaniel3 on configuring one's audio hardware with pulse audio. It complements this blog post of mine nicely and jdmcdaniel3's blog entry is a very valuable, very quick and recommended read.

Sandbox PC - playback
(1) pavucontrol configuration tab on my Sandbox PC
(2) pavucontrol output devices tab on my Sandbox PC
(3) pavucontrol playback tab on my Sandbox PC
(4) PulseAudio equalizer on my Sandbox PC
(5) pavucontrol input devices tab on my Sandbox PC

and a series of posts using my 2 year old Primary PC (which has integrated motherboard sound, and a webcam with an integrated microphone)

Primary PC -recording
(1) pavucontrol configuration tab on my Primary PC
(2) pavucontrol input devices tab on my Primary PC
(3) pavucontrol recording tab to use the webcam microphone with skype

Recording one's desktop with ffmpeg and pavucontrol
(1) record computer audio and audio from mic while capturing desktop with ffmpeg - Note this is on a different blog entry - click on the link to go there.

.... continued ...

Submit "Pulseaudio Basics for openSUSE with pavucontrol" to Digg Submit "Pulseaudio Basics for openSUSE with pavucontrol" to del.icio.us Submit "Pulseaudio Basics for openSUSE with pavucontrol" to StumbleUpon Submit "Pulseaudio Basics for openSUSE with pavucontrol" to Google Submit "Pulseaudio Basics for openSUSE with pavucontrol" to Facebook Submit "Pulseaudio Basics for openSUSE with pavucontrol" to Twitter

Updated 05-May-2013 at 03:32 by oldcpu

Tags: None Add / Edit Tags
Categories
Technical Advice

Comments

  1. oldcpu's Avatar
    My Sandbox PC is a home assembled PC with an ancient MSI KT3 Ultra ATX (KT333) motherboard with a slow 32-bit athlon-1100 CPU. It is running a 32-bit openSUSE-11.4 with the LXDE desktop.

    It has two sound devices:
    • motherboard integrated audio device (Microstar/VIA VT8233 … with ALC650D hardware audio codec) using the snd_via82xx kernel module
    • Ensoniq PCI audio card (sound blaster PCI-128 compatible) using the snd_ens1371 kernel module


    The arecord and aplay commands provide these details:
    Code:
    oldcpu@sandboxpc:~> aplay -l
    **** List of PLAYBACK Hardware Devices ****
    card 0: V8233A [VIA 8233A], device 0: VIA 8233A [VIA 8233A]
      Subdevices: 1/1
      Subdevice #0: subdevice #0
    card 0: V8233A [VIA 8233A], device 1: VIA 8233A [VIA 8233A]
      Subdevices: 1/1
      Subdevice #0: subdevice #0
    card 1: AudioPCI [Ensoniq AudioPCI], device 0: ES1371/1 [ES1371 DAC2/ADC]
      Subdevices: 1/1
      Subdevice #0: subdevice #0
    card 1: AudioPCI [Ensoniq AudioPCI], device 1: ES1371/2 [ES1371 DAC1]
      Subdevices: 1/1
      Subdevice #0: subdevice #0
    Code:
    oldcpu@sandboxpc:~> arecord -l
    **** List of CAPTURE Hardware Devices ****
    card 0: V8233A [VIA 8233A], device 0: VIA 8233A [VIA 8233A]
      Subdevices: 1/1
      Subdevice #0: subdevice #0
    card 1: AudioPCI [Ensoniq AudioPCI], device 0: ES1371/1 [ES1371 DAC2/ADC]
      Subdevices: 1/1
      Subdevice #0: subdevice #0
    pavucontrol Configuration Tab on my Sandbox PC

    The application pavucontrol configuration tab looks like this where the motherboard sound is card-0 and the PCI card is card-1:


    Perhaps a criticism I have of pavucontrol application is it is not always possible to easily identify which control is associated with which audio device (although sometimes it is easy).

    If we look at the PCI card (sound card 1) we can see its configuration selections here:


    I don't have 5.1 surround sound speakers connected to this PC, so for this audio device (as can be seen above) I have selected a simple analog stereo output and a simple analog mono input.
    Updated 07-Jan-2012 at 11:55 by oldcpu
  2. oldcpu's Avatar
    pavucontrol Output Devices Tab on my Sandbox PC

    The output devices tab is where one can select their default hardware device, or mute the hardware device, and control the volume if need be (I prefer NOT to control the volume from here – rather I control the volume from the mixer that comes with openSUSE's LXDE desktop).

    This first image illustrates the hardware output devices. Ie Card-0 (motherboard) and Card-1 (PCI card). Note the 'SHOW' filter set to 'Hardware Output Devices'. This is NOT my recommended setting.


    This next image illustrates that I have a 'virtual output device' installed on this PC. In fact, it is the application pulseaudio-equalizer that is easily downloadable and installed from Packman packagers web site: PackMan :: Informationen zum Paket pulseaudio-equalizer . Note the 'SHOW' filter set to 'Virtual Output Devices' . This is NOT my recommended setting.


    This next image illustrates the 'SHOW' filter set to 'All Output Devices'. This is the setting I typically recommend as it show all devices, both hardware and virtual.
    Updated 07-Jan-2012 at 11:54 by oldcpu
  3. oldcpu's Avatar
    pavucontrol Playback Tab on my Sandbox PC

    The playback tab is where one can select different audio devices , and different volume levels, on an application level. This is one of the neat features of pulseaudio.

    So here in this next image is SMPlayer playing back a music video with pavucontrol just below it.


    Lets take a closer look. In this image you can see I have Smplayer set to send its audio to the Equalizer. And I have the Equalizer set to send its sound to one of my output devices (in this case it happens to be the PCI sound blaster compatible card – again, the pavucontrol labelling leaves a bit to be desired here).


    This next image illustrates the choices I had with Smplayer. I could have had it send its audio to Sound Card 0 (the integrated motherboard audio device), or to Card 1 (the PCI sound blaster audio device) , or to the PulseAudio Equalizer application. I chose the Equalizer Application.


    And one can see from the above that the PulseAudio Equalizer is sending its audio to “Internal Audio Analog Stereo” which is in fact Sound Card 1 (the PCI sound blaster audio device).

    Its all pretty simple.
    Updated 07-Jan-2012 at 11:54 by oldcpu
  4. oldcpu's Avatar
    Pulseaudio-Equalizer on my Sandbox PC

    Now in case you are curious about the PulseAudio Equalizer, its GTK GUI looks like this:


    It can be run with the command
    Code:
    pulseaudio-equalizer-gtk
    and it has many preselections available for the mixer, as seen here:


    and here is the mixer being shown at the same the output devices tab
    Updated 07-Jan-2012 at 14:25 by oldcpu
  5. oldcpu's Avatar
    pavucontrol Input Devices on my Sandbox PC

    The Input Devices is where one can control some of their Microphone and Line-In settings to Pulse Audio. So this next image illustrates what the Input Devices look like on my Sandbox PC with 'SHOW' set to 'All Except Monitors'. One can clearly see Sound Card 0 (my integrated motherboard sound) and Sound Card 1 (the PCI sound blaster compatible card).


    The next image (again the Input Devices Tab) illustrates that there are NO Virtual Input Devices setup.


    The next image is complex, and it has the 'SHOW' filter set to 'All Input Devices'. Here one can see not only the input to the sound devices, but can also see the control for pulse audio monitoring of this input. This separation of the 'monitor' can be very useful for more advanced users who want to take the input of a device and send it to multiple locations.


    Now I am NOT going to show the recording setup with this Sandbox PC, but rather I am now going to shift to my Primary PC and show pulseaudio running there with the application 'Skype'.
    Updated 07-Jan-2012 at 11:55 by oldcpu
  6. oldcpu's Avatar
    My 2 year old Primary PC has an Asus P6T Deluxe V2 motherboard, with a moderate Intel Core i7 920 CPU (quad core). It is running a 64-bit openSUSE-11.4 with the stock KDE desktop. It has two sound devices:
    • card0 - motherboard integrated audio device (AD1989B hardware audio codec) using the snd_hda_intel kernel module
    • card1 - Logitech C910 webcam with its integrated Microphone using the snd_usb_audio kernel module


    The arecord and aplay commands provide these details:
    Code:
    oldcpu@primarypc:~> aplay -l
    **** List of PLAYBACK Hardware Devices ****
    card 0: Intel [HDA Intel], device 0: AD198x Analog [AD198x Analog]
      Subdevices: 1/1
      Subdevice #0: subdevice #0
    card 0: Intel [HDA Intel], device 1: AD198x Digital [AD198x Digital]
      Subdevices: 1/1
      Subdevice #0: subdevice #0
    Code:
    oldcpu@primarypc:~> arecord -l
    **** List of CAPTURE Hardware Devices ****
    card 0: Intel [HDA Intel], device 0: AD198x Analog [AD198x Analog]
      Subdevices: 3/3
      Subdevice #0: subdevice #0
      Subdevice #1: subdevice #1
      Subdevice #2: subdevice #2
    card 1: U0x46d0x821 [USB Device 0x46d:0x821], device 0: USB Audio [USB Audio]
      Subdevices: 1/1
      Subdevice #0: subdevice #0
    pavucontrol Configuration Tab on Primary PC

    The application pavucontrol configuration tab looks like this where the motherboard sound is card-0 and the webcam USB microphone is card-1:


    If we look at the motherboard card (sound card 0) we can see its configuration selections here:

    where for this PC I DO have a 5.1 surround sound speaker system plugged in, so I selected that pulse audio setting together with an analog stereo input for the microphone jacks on the motherbord.

    If we look at the webcam's settings (sound card 1) one can see I have Digital Stereo (IEC958) set. Webcam microphones are often digital so this was the setting I first went for.
    Updated 08-Jan-2012 at 09:09 by oldcpu
  7. oldcpu's Avatar
    pavucontrol Input Devices Tab on Primary PC

    As noted above, the Input Devices is where one can control some of their Microphone and Line-In settings to Pulse Audio.

    In this image I have the 'SHOW' filter set to 'Hardware Input Devices' (which is nominally NOT a setting I recommend) and it clearly illustrates my motherboard have the input jack 'Microphone1' selected).

    The actual 'Port' selection is:
    • Microphone 1
    • Microphone 2
    • Line In

    which correspond to different hardware audio inputs to my motherboard. The Microphone1 and Microhone2 correspond to front and rear microphone jacks.

    This next image illustrates there are no Virtual Input devices.


    This next image illustrates the Input Devices 'monitor' control for the surround sound audio … (where 'SHOW' is set to 'Monitors' (which nominally is NOT a setting I recommend).


    This next Input Devices image has 'SHOW' set to 'All Input Devices' and it illustrates both the Hardware (motherboard input and webcam input) and Monitor (of surround sound) controls.

    One can mute a mic here, and control the capture. I normally leave this 'as is' and don't play with it.
    Updated 07-Jan-2012 at 11:53 by oldcpu
  8. oldcpu's Avatar
    pavucontrol Recording Tab on Primary PC

    This next image shows the recording Tab when I have no recording applications running.


    Setting Up Skype in Pulseaudio

    For this blog, I want to illustrate a Skype setup, so this next image illustrates Skype running, and in the Skype preferences I have under 'Sound Devices' selected 'PulseAudio server (local) everywhere.


    I then selected the Skype 'Make a Test Call' selection, and while that was running I went to the pavucontrol 'Recording Tab'. I was careful to select 'Show' 'All Streams'. You can see Skype here and in order to use the Webcam's microphone, I was careful to select '0821 Digital Stereo (IEC958)' .


    Here are the selections I had to choose from:


    And thats it.

    Please if your pulse audio does NOT work for you, despite trying to mimic my setup, ASK FOR HELP in a FORUM thread. Please do NOT ask for help here in this blog.

    Many thanks and good luck in your pulse audio efforts.
    Updated 07-Jan-2012 at 14:20 by oldcpu
  9. jdmcdaniel3's Avatar
    Here are a couple of more good links on Audio Setup:

    YaST & Multimedia setup in KDE: https://forums.opensuse.org/english/...idia-670m.html

    HDMI Setup for nVIDIA: https://forums.opensuse.org/english/...ml#post2500622

    There are so many possibilities it would seem.

    Thank You,
  10. oldcpu's Avatar
    Quote Originally Posted by jdmcdaniel3
    Here are a couple of more good links on Audio Setup:
    jdmcdaniel3, many thanks for your input. I also note you have a new EXCELLENT blog entry on this subject located here: https://forums.opensuse.org/blogs/jd...iguration-139/

    ... and I took the liberty of referencing your recent blog entry in my 1st post above.
  11. jdmcdaniel3's Avatar
    Quote Originally Posted by oldcpu
    jdmcdaniel3, many thanks for your input. I also note you have a new EXCELLENT blog entry on this subject located here: https://forums.opensuse.org/blogs/jd...iguration-139/

    ... and I took the liberty of referencing your recent blog entry in my 1st post above.
    Hey and I have added a link in my new blog pointing back to here. My main point is the problem with multiple sound cards and the need to disable the ones you do not use. You can also put a preference on a certain sound card if you need to keep more than one enabled. I might add that to my blog as well but in any event, considerable more information about pavucontrol is mentioned here. I can say that finally, I can type pavucontrol as one word without looking it up anymore. Perhaps a personnel problem when you get older. But at least I have not chose to actually use the word old in my online name.

    Thank You for using openSUSE,
    Updated 06-May-2013 at 20:46 by jdmcdaniel3

Search Engine Friendly URLs by vBSEO 3.5.2 PL2