OpenWrt Forum Archive

Topic: alsamixer

The content of this topic has been archived on 20 Apr 2018. There are no obvious gaps in this topic, but there may still be some posts missing at the end.

Hope someone can help with what should be a simple problem.

Im compiling Kamikaze for linux 2.6 on wgt634u, I have a usb sound card and want to control the audio levels, specifically the mic input level.

How can I compile and use alsamixer?  The alsa-utils package wont work without the alsa-libs package and that will only work for linux 2.4!!!

Is there any way to get alsamixer working on 2.6 easily?

Thanks

John

Hello

Dont know if anyone else is having problems with ALSA and in particular alsamixer.

Having reviewed the source of the alsa package, I have found a problem: when alsamixer runs, it looks for a "control" device in /dev/snd - for a single sound card this would normally be /dev/snd/controlC0

(for those interested it seems to be hardcoded in build_mipsel/alsa-lib-1.0.13/include/config.h :
line 8: #define ALSA_DEVICE_DIRECTORY "/dev/snd"
this is a .configure generated file so maybe getting the default from my build system? i dont know quite how it works)

Openwrt currently creates that device as /dev/controlC0

so alsamixer cannot find the mixer device.

I created a symlink :

mkdir /dev/snd
ln -s /dev/controlC0 /dev/snd/controlC0

and now alsamixer runs, I can control volume and capture characteristics.

There are probably other problems (e.g. i expect alsa will expect /dev/snd/pcmC0D0c and p also for actual playback using Alsa) here and surely there is a better solution (OpenWRT developers - can we create alsa devices in /dev/snd by default???)

Thanks

John

The discussion might have continued from here.