Scheduled Maintenance: We are aware of an issue with Google, AOL, and Yahoo services as email providers which are blocking new registrations. We are trying to fix the issue and we have several internal and external support tickets in process to resolve the issue. Please see: viewtopic.php?t=158230

 

 

 

HOWTO systemwide eq with alsaequal

Share your HowTo, Documentation, Tips and Tricks. Not for support questions!.
Message
Author
Polaris96
Posts: 555
Joined: 2009-06-17 18:37

Re: HOWTO systemwide eq with alsaequal

#16 Post by Polaris96 »

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.

g1annos
Posts: 122
Joined: 2008-12-01 02:15

Re: HOWTO systemwide eq with alsaequal

#17 Post by g1annos »

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.

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

Re: HOWTO systemwide eq with alsaequal

#18 Post by vortex636 »

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!

g1annos
Posts: 122
Joined: 2008-12-01 02:15

Re: HOWTO systemwide eq with alsaequal

#19 Post by g1annos »

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.

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

Re: HOWTO systemwide eq with alsaequal

#20 Post by vortex636 »

Έστω και καθυστερημένα, ευχαριστώ Γιαννο ! :)

g1annos
Posts: 122
Joined: 2008-12-01 02:15

Re: HOWTO systemwide eq with alsaequal

#21 Post by g1annos »

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

-----------------------------------
Γεια σου φίλε. Επλίζω με αυτό το τελευταίο να βοήθησα ;-)

User avatar
phenest
Posts: 1702
Joined: 2010-03-09 09:38
Location: The Matrix

Re: HOWTO systemwide eq with alsaequal

#22 Post by phenest »

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: 1702
Joined: 2010-03-09 09:38
Location: The Matrix

Re: HOWTO systemwide eq with alsaequal

#23 Post by phenest »

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: 1702
Joined: 2010-03-09 09:38
Location: The Matrix

Re: HOWTO systemwide eq with alsaequal

#24 Post by phenest »

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

notzeus
Posts: 19
Joined: 2011-01-28 15:05

Re: HOWTO systemwide eq with alsaequal

#25 Post by notzeus »

Walkthrough works fine with squeeze !!! Thx!

User avatar
Job
Posts: 813
Joined: 2006-12-30 20:20
Location: no clue
Contact:

Re: HOWTO systemwide eq with alsaequal

#26 Post by Job »

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
--------------------------------------------------------------------------------------------------------------
Debian 12 - FreeBSD

User avatar
phenest
Posts: 1702
Joined: 2010-03-09 09:38
Location: The Matrix

Re: HOWTO systemwide eq with alsaequal

#27 Post by phenest »

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

robertpdx
Posts: 1
Joined: 2012-10-10 19:35

Re: HOWTO systemwide eq with alsaequal

#28 Post by robertpdx »

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.

ant
Posts: 355
Joined: 2011-11-09 00:15

Re: HOWTO systemwide eq with alsaequal

#29 Post by ant »

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: 355
Joined: 2011-11-09 00:15

Re: HOWTO systemwide eq with alsaequal

#30 Post by ant »

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: 355
Joined: 2011-11-09 00:15

Re: HOWTO systemwide eq with alsaequal

#31 Post by ant »

ant wrote: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
...
The author kindly replied to my e-mail and told me to try local ~/.asoundrc instead. That worked for mpg321 player, but not mpg123:
mpg123 -a hw:equal Rat\ Soufflé\ -\ Doctor\ Who\ \(Howell\ 2010\
Mix\).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
Cannot create thread 1 Operation not permitted
Cannot create thread 1 Operation not permitted
JACK server starting in realtime mode with priority 10
Cannot lock down memory area (Cannot allocate memory)
audio_reservation_init
Acquire audio card Audio0
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
ittle-endian
ALSA: use 2 periods for playback
Cannot use real-time scheduling (RR/10)(1: Operation not permitted)
AcquireSelfRealTime error
Cannot lock down memory area (Cannot allocate memory)
Registered as JACK client mpg123-11097.
Cannot use real-time scheduling (RR/5)(1: Operation not permitted)
AcquireRealTime error
Unknown destination port in attempted (dis)connection src_name
[mpg123-11097: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
[pulse.c:84] error: Failed to open pulse audio output: Invalid argument
[nas.c:222] error: could not open NAS server hw:equal

Released audio card Audio0
audio_reservation_finish
[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.

Weird. It looks like I have to tell each audio player to use Alsa's "equal" hw. Is there a way to force this by default for ALL software for audio? I couldn't figure out how to get my XMMS, Mplayer, web browsers, Gnome v2.23, VLC, etc. to use it by default. Is there a way to do that? :( https://johan.pp.se/2011/02/20/systemwi ... -equalizer says you just restart the software which I did. Does it require a reboot?

andoru
Posts: 272
Joined: 2014-03-14 16:59

Re: HOWTO systemwide eq with alsaequal

#32 Post by andoru »

Sorry for necromancing, but I couldn't find any other better thread for my question.
Just as Job posted earlier, I successfully installed libasound2-plugin-equal, alsamixer -D equal brings up the equalizer as expected, but no matter how I change it, it seems to not change the sound in VLC, it still sounds flat as if there were no equalizer. Any fix for it?

patrick013
Posts: 84
Joined: 2013-02-07 19:08

Re: HOWTO systemwide eq with alsaequal

#33 Post by patrick013 »

I installed the equalizer per this, works fine all around.
Used the libasound2-plugin-equal equalizer plugin for
ALSA in the stable repo.


PCLinuxOS Magazine - Page 11

:D

Polaris96
Posts: 555
Joined: 2009-06-17 18:37

Re: HOWTO systemwide eq with alsaequal

#34 Post by Polaris96 »

TO ALL

Please be advised this HOW TO is pretty deprecated at this point. The most signifigant issue you'll likely encounter is a loss of functionality (or, rather, unpredictable functionality) when you've also got PulseAudiou installed.

ALSA and Pulse conduct a constant tug-o-war over which process gets the stream LAST. because of this, you might have some real issues with using alsaequal on a PA equipped system. I haven't been able to resolve this and don't have the time, right now to dig deeply into

b/r $POLARIS
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.

patrick013
Posts: 84
Joined: 2013-02-07 19:08

Re: HOWTO systemwide eq with alsaequal

#35 Post by patrick013 »

Polaris96 wrote:TO ALL
Please be advised this HOW TO is pretty deprecated at this point.
b/r $POLARIS
I ran mine with Pulse and it ran just as good. But, if you have Pulse
you really don't need it and can do some recording, LAN, etc.. a little
better also with Pulse. But to say it is deprecated on an ALSA only
system, I wouldn't go that far. Makes Flash, AlsaPlayer, Totem,
everything soundwise OK with a 3.13.x kernel.

regards,

P

Post Reply