Difference between revisions of "Equalizer for ALSA"

From LinuxMCE
Jump to: navigation, search
(Installation)
 
(2 intermediate revisions by 2 users not shown)
Line 1: Line 1:
[[Category:Documentation]]
+
[[Category:Audio| ]]
[[Category:Audio]]
+
[[Category:Tutorials]]
+
  
 
{{versioninfo|810Status=Relevant|810UpdatedDate=19th July 2011|810UpdatedBy=purps}}
 
{{versioninfo|810Status=Relevant|810UpdatedDate=19th July 2011|810UpdatedBy=purps}}

Latest revision as of 22:45, 19 October 2012


Version Status Date Updated Updated By
710 Unknown N/A N/A
810 Relevant 19th July 2011 purps
1004 Unknown N/A N/A
1204 Unknown N/A N/A
1404 Unknown N/A N/A
Usage Information

Introduction

ALSA stands for Advanced Linux Sound Architecture, and is a Linux kernel component for providing device drivers for sound cards. This page aims to walk you through the steps of installing an ALSA plugin called alsaequal that will give you a graphical equalizer on the command line. Doing this will allow you to fine tune the various frequency strengths i.e. bass, treble, etc.

I decided to do this because my speakers do not have any bass control, but to be honest, it's a great way of getting that perfect sound from your system. Yes I'm sure many people have fancy Hi-Fis and amplifiers that can do all of this, but if like me you are not an audiophile, but want to get the best out of the equipment that you have, then this is a good way to go. AND it can be done remotely.


Preparation

The setup and use of the plugin is all done on the command line. So you can either open up a terminal on the MD itself, or ssh into it (see Logging In for details). So do that first.


If you are not already, make yourself root...

sudo su -


Just check you are in the root equivalent of the home directory by typing...

pwd

...the output of which should be "/root" - if not, the command "cd /root" will put you in the right place.


Before we can start, we need to install a few dependencies...

apt-get install build-essential caps libasound2-dev libasound2-plugins

(you may find some or all of these are already installed).


And finally, we need to download the alsa equalizer plugin itself...

wget http://www.thedigitalmachine.net/tools/alsaequal-0.6.tar.bz2

Installation

Firstly, we need to uncompress what we have just downloaded, using...

tar -xjvvf alsaequal-0.6.tar.bz2


Then we need to enter the folder that has just been extracted (type "ls" to list what is in the current directory if you don't believe me). This folder contains the goodies we need to complete the installation...

cd alsaequal


And now for the make/install stuff...

make clean
make

...checking there aren't any errors. And then...

make install
make clean

...and that's it, alsaequal is now installed.


But we're not quite done. Before alsaequal will work properly, we have to set up a configuration file, enabling alsaequal to interact with ALSA. This is as simple as making a blank file in "/root" called ".asoundrc". As a beginner, I like to use nano, so I would type...

nano /root/.asoundrc

...but remember nano is not installed by default. You can use vi or vim or whatever it is called instead if you're a bit of a pro.


Either way, paste the following into the blank file...

 ctl.equal {
     type equal;
   }
   pcm.plugequal {
     type equal;
     # Modify the line below if you don't
     # want to use sound card 0.
     slave.pcm "plug:dmix";
   }
   # pcm.equal {
     # Or if you want the equalizer to be your
     # default soundcard uncomment the following
     # line and comment the above line.
   pcm.!default {
     type plug;
     slave.pcm plugequal;
   }

...and save.


Now restart ALSA with...

alsa force-reload

Usage

To access and adjust the equalizer settings, simply type...

alsamixer -D equal

As with alsamixer, pressing Esc will exit.