HOWTO systemwide eq with alsaequal

Share your own howto's etc. Not for support questions!

Re: HOWTO systemwide eq with alsaequal

Postby Polaris96 » 2011-02-11 13:44

you must have .asoundrc to make alsa equal work. .asoundrc tells alsa to use the equalizer. if it isn't there, Alsa won't know to stream through the equalizer. I'm really not sure why this would make skype fail to function. If time permits I'll look into it, but I don't use skype so I might not get to it (sorry)

You might consider some of the open source skype alternatives that are become available, btw.
for as long as the world remains. for as long as time remains. so, too, will I remain. To serve. To help. And to make my contribution. Also, never forget our family at debianuserforums.org If we can't solve your problem, they probably can.
Polaris96
 
Posts: 555
Joined: 2009-06-17 18:37

Re: HOWTO systemwide eq with alsaequal

Postby g1annos » 2011-02-11 14:48

you must have .asoundrc to make alsa equal work. .asoundrc tells alsa to use the equalizer. if it isn't there, Alsa won't know to stream through the equalizer.
You are right. I cannot read the code to understand why .asoundrc is necessary but I confirmed it experimentally.

I'm really not sure why this would make Skype fail to function.
Maybe that doesn't happen in 32bit version. Unfortunately Skype hasn't release yet a 64bit version for Debian, so I forced install the 64bit Ubuntu package. Then I installed the qt4 dependencies of 32bit sound libraries (ia32-libs ia32-libs-gtk libqt4-core libqt4-gui) and finally I deleted the 32bit pulse plugins (rm -f /usr/lib32/libpulse*) --> IF rm -f /usr/lib32/libpulse* isn't done Skype crashes.

Thus it is a lot complicated for me to understand which is the conflict of .asoundrc, after all that.

You might consider some of the open source skype alternatives that are become available, btw.
It would be the best. But are there any open source alternatives able to communicate with Skype?

Thanks a lot.
g1annos
 
Posts: 122
Joined: 2008-12-01 02:15

Re: HOWTO systemwide eq with alsaequal

Postby vortex636 » 2011-04-06 21:24

Hello!

This an awsome post, thank you so much for taking the time and effort to write it.
It worked perfectly for me, but for one simple problem: the .asounrdrc pcm configuration disabled my microphone.
While trying to reconfigure it, i got an error that dmix plugin does not support capture devices.
You wouldn't happen to know of a workaround for this would you?
So far I had to disable the asoundrc and alsaequal whenever I wanna skype...
Is there a way to add in asoundrc more than the pcm in order to use both alsaequal and the microphone?

Thanks!
vortex636
 
Posts: 53
Joined: 2010-11-24 02:39

Re: HOWTO systemwide eq with alsaequal

Postby g1annos » 2011-04-07 07:56

So far I had to disable the asoundrc and alsaequal whenever I wanna skype...
Is there a way to add in asoundrc more than the pcm in order to use both alsaequal and the microphone?
In my situation it totally mutes Skype. Not just the mic. Skype does not have sound at all.

I guess that you have 64bit version of Debian. Right? And you forced the Skype version.

I did exactly that, and then installed the 32bit libraries and qt4 dependencies, and then I removed (rm *) the 32bit libpulse plugins from lib32in order for Skype no to crash. I believe that there is where the problem is established and thus cannot have asoundrc with Skype working together.
g1annos
 
Posts: 122
Joined: 2008-12-01 02:15

Re: HOWTO systemwide eq with alsaequal

Postby vortex636 » 2011-06-09 12:13

Έστω και καθυστερημένα, ευχαριστώ Γιαννο ! :)
vortex636
 
Posts: 53
Joined: 2010-11-24 02:39

Re: HOWTO systemwide eq with alsaequal

Postby g1annos » 2011-06-16 15:01

What finally works great with Skype is the following:

1. install libasound2-plugin-equal
Code: Select all
apt-get install libasound2-plugin-equal

2. open a new file (.asoundrc) in homefolder
Code: Select all
gedit ~/.asoundrc

3. copy the following options
Code: Select all
ctl.equal {
   type equal;
}

pcm.plugequal {
    type equal;
   slave.pcm "plughw:0,0";
}

pcm.equal{
    type plug;
    slave.pcm plugequal;
}

4. save and exit

5. run asla equalizer
Code: Select all
alsamixer -D equal


Have fun

-----------------------------------
Γεια σου φίλε. Επλίζω με αυτό το τελευταίο να βοήθησα ;-)
g1annos
 
Posts: 122
Joined: 2008-12-01 02:15

Re: HOWTO systemwide eq with alsaequal

Postby phenest » 2011-10-29 17:38

This work great. But... how to set it up for 2.1 channels? My laptop has a subwoofer (LFE) and the volume control adjusts the PCM leaving the Master and LFE at max. With alsaequal installed, adjusting PCM does nothing, only Master and LFE for volume work. Any reason/fix for this?
ASRock H77 Pro4-M i7 3770K - 32GB RAM - Pioneer BDR-209D
User avatar
phenest
 
Posts: 1704
Joined: 2010-03-09 09:38
Location: The Matrix

Re: HOWTO systemwide eq with alsaequal

Postby phenest » 2011-10-29 18:47

Incidentally, I was thinking I could package this and put it in my public repository (see sig). Seems simple enough, 2 libraries, and I could add a .desktop file for alsamixer for easy access.
ASRock H77 Pro4-M i7 3770K - 32GB RAM - Pioneer BDR-209D
User avatar
phenest
 
Posts: 1704
Joined: 2010-03-09 09:38
Location: The Matrix

Re: HOWTO systemwide eq with alsaequal

Postby phenest » 2011-10-31 17:22

Polaris96 wrote:One last thing:
Code: Select all
  ~#alsa force-reload


This tends to make apps crash. A better way is to (as root):
Code: Select all
/etc/init.d/alsa-utils restart

This is also the way I've used in my package.

Polaris96 wrote:When you want to shut the alsamixer utility, double-tap [esc]

Double tap?
ASRock H77 Pro4-M i7 3770K - 32GB RAM - Pioneer BDR-209D
User avatar
phenest
 
Posts: 1704
Joined: 2010-03-09 09:38
Location: The Matrix

Re: HOWTO systemwide eq with alsaequal

Postby notzeus » 2012-03-05 20:16

Walkthrough works fine with squeeze !!! Thx!
notzeus
 
Posts: 19
Joined: 2011-01-28 15:05

Re: HOWTO systemwide eq with alsaequal

Postby Job » 2012-08-05 16:25

Everything went well here but the equalizer has no impact on my sound. This is a Sid installation. The same installation also successfully has impact on the sound system of a Squeeze machine. Any idea guys?
Cheers

Image
Image
#aptitude install life
--------------------------------------------------------------------------------------------------------------
Devuan Beowulf - FreeBSD - Jessie (Media Center, yes, believe it)
User avatar
Job
 
Posts: 800
Joined: 2006-12-30 20:20
Location: no clue

Re: HOWTO systemwide eq with alsaequal

Postby phenest » 2012-08-26 20:47

This is now available as an Alsa plugin in Wheezy.
Code: Select all
apt-get install libasound2-plugin-equal

Works fine, but gives an error:
Code: Select all
alsamixer -D equal
ALSA lib control.c:951:(snd_ctl_open_noupdate) Invalid CTL equal
cannot open mixer: No such file or directory

if the ~/.asoundrc file is missing.

EDIT:
I've reported this as a bug: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=685955
ASRock H77 Pro4-M i7 3770K - 32GB RAM - Pioneer BDR-209D
User avatar
phenest
 
Posts: 1704
Joined: 2010-03-09 09:38
Location: The Matrix

Re: HOWTO systemwide eq with alsaequal

Postby robertpdx » 2012-10-10 19:54

I followed the instructions from the first post on my Ubuntu 11.10 (oneiric) server, configuring the .asoundrc file to set the equal plugin as default, and found that it works when I invoke it specifically like this:

$ mpeg123 -a default file.mp3
is processed through the EQ

However, if I just call the player without the -a and cardname, it plays, but not EQ'd.
e.g.
$ mpeg123 file.mp3
does not use the EQ.

Any suggestions on further settings? It's an IBM ThinkCentre desktop with an onboard Intel 82801EB ICH5 - AC'97 Audio Controller.
robertpdx
 
Posts: 1
Joined: 2012-10-10 19:35

Re: HOWTO systemwide eq with alsaequal

Postby ant » 2012-12-24 01:59

Hello.

I tried to get this to work from http://www.thedigitalmachine.net/alsaequal.html and this forum thread. However, its EQ doesn't seem to work for me on my over year old Debian stable box with http://www.thedigitalmachine.net/tools/ ... .6.tar.bz2. I had no problems compiling it though:

# nano /root/.asoundrc
# alsa force-reload
Terminating processes: 8965.
Unloading ALSA sound driver modules: snd-seq-midi snd-rawmidi snd-seq-midi-event snd-seq snd-seq-device snd-pcm-oss snd-mixer-oss snd-hda-intel snd-hda-codec-realtek snd-hda-codec snd-hwdep snd-pcm snd-timer snd-page-alloc.
Loading ALSA sound driver modules: snd-seq-midi snd-rawmidi snd-seq-midi-event snd-seq snd-seq-device snd-pcm-oss snd-mixer-oss snd-hda-intel snd-hda-codec-realtek snd-hda-codec snd-hwdep snd-pcm snd-timer snd-page-alloc.

$ alsamixer -D equal
ALSA lib control.c:882:(snd_ctl_open_noupdate) Invalid CTL equal
cannot open mixer: No such file or directory

If I run it as root, then no problems. However, none of the music sound different with the EQ changes. I basically wanted to add more bass by increasing the left volumes higher.

# mpg321 -a hw:equal Tao\ -\ Ultraflow.mp3
High Performance MPEG 1.0/2.0/2.5 Audio Player for Layer 1, 2, and 3.
Version 0.2.12-1 (2010/07/01). Written and copyrights by Joe Drew,
now maintained by Nanakos Chrysostomos and others.
Uses code from various people. See 'README' for more!
THIS SOFTWARE COMES WITH ABSOLUTELY NO WARRANTY! USE AT YOUR OWN RISK!
Title : Ultraflow Artist : Tao
Album : Seven Year : 2011
Comment : http://www.8bitpeoples.com Genre : Chip Music

Playing MPEG stream from Tao - Ultraflow.mp3 ...
MPEG 1.0 layer III, 192 kbit/s, 44100 Hz joint-stereo
ALSA lib pcm.c:2190:(snd_pcm_open_noupdate) Unknown PCM equal
Can't open libao driver with device hw (is device in use?)

# mpg123 -a hw:equal Tao\ -\ Ultraflow.mp3
Cannot connect to server socket err = No such file or directory
Cannot connect to server socket
jackdmp 1.9.6
Copyright 2001-2005 Paul Davis and others.
Copyright 2004-2010 Grame.
jackdmp comes with ABSOLUTELY NO WARRANTY
This is free software, and you are welcome to redistribute it
under certain conditions; see the file COPYING for details
no message buffer overruns
no message buffer overruns
JACK server starting in realtime mode with priority 10
Failed to connect to session bus for device reservation Did not receive a reply. Possible causes include: the remote application did not send a reply, the message bus security policy blocked the reply, the reply timeout expired, or the network connection was broken.

Failed to acquire device name : Audio0 error : Invalid argument
Audio device hw:0 cannot be acquired, trying to open it anyway...
creating alsa driver ... hw:0|hw:0|1024|2|48000|0|0|nomon|swmeter|-|32bit
Using ALSA driver HDA-Intel running on card 0 - HDA Intel at 0xf7ff8000 irq 22
configuring for 48000Hz, period = 1024 frames (21.3 ms), buffer = 2 periods
ALSA: final selected sample format for capture: 32bit integer little-endian
ALSA: use 2 periods for capture
ALSA: final selected sample format for playback: 32bit integer little-endian
ALSA: use 2 periods for playback
Registered as JACK client mpg123-20651.
Unknown destination port in attempted (dis)connection src_name [mpg123-20651:left] dst_name [hw:equal]
[jack.c:125] error: connect_jack_ports(): failed to jack_connect() ports: -1
JackTemporaryException : now quits...
jack main caught signal 2
No protocol specified
XOpenDisplay() failed
[pulse.c:84] error: Failed to open pulse audio output: Connection refused
[nas.c:222] error: could not open NAS server hw:equal

Audio card Audio0 not found!!
[audio.c:625] error: failed to open audio device
[audio.c:180] error: Unable to find a working output module in this list: alsa,oss,esd,jack,pulse,nas,arts
[audio.c:527] error: Failed to open audio output module
[mpg123.c:847] error: Failed to initialize output, goodbye.


I even tried rebooting in case something was stuck. What's wrong? I probably messed up somewhere! :(

Thank you in advance. :)
Last edited by ant on 2012-12-24 02:20, edited 1 time in total.
ant
 
Posts: 313
Joined: 2011-11-09 00:15

Re: HOWTO systemwide eq with alsaequal

Postby ant » 2012-12-24 02:12

robertpdx wrote:I followed the instructions from the first post on my Ubuntu 11.10 (oneiric) server, configuring the .asoundrc file to set the equal plugin as default, and found that it works when I invoke it specifically like this:

$ mpeg123 -a default file.mp3
is processed through the EQ

However, if I just call the player without the -a and cardname, it plays, but not EQ'd.
e.g.
$ mpeg123 file.mp3
does not use the EQ.

Any suggestions on further settings? It's an IBM ThinkCentre desktop with an onboard Intel 82801EB ICH5 - AC'97 Audio Controller.
I believe you need to add hw:equal parameter for that command line for EQ to work because you have to tell the player to use it. :(
ant
 
Posts: 313
Joined: 2011-11-09 00:15

PreviousNext

Return to Docs, Howtos, Tips & Tricks

Who is online

Users browsing this forum: Islander, w4kh and 3 guests

fashionable