http://alsa.opensrc.org/Realtek_ALC861
I found this:
Try muting the line-in on the sound card.
> alsamixer
Then hit tab to change device types (playback vs input vs all) hit 'm' to mute a device. Or at least turn it down to 0 if you don't have a mute option.
Originally posted by: ciproxr
When i installed ubuntu the sound automaticly worked but the quality wasent that great, seemed to work at reduced performance, its hard to describe but i could sometimes hear hissing noises and some songs it almost sounds like their lower quality but in windows they play great.
These devices require what is known as 'software mixing' in order to function correctly.. that is to have more then one sound at a time. The hardware in most types of sound cards nowadays are pretty simple and can only handle one sound input at a time coming from the OS.
Traditionally in Linux these things were troublesome because by default there was no sound mixing at all and when one application was making a sound no other application could access the sound card. With software mixing this is now possible, but with applications that use a old fasion way of accessing the sound system (called OSS, were the modern one is ALSA) (like Quake3-style games still use OSS) this can still be troublesome.
In Windows this is handled very automaticly since Win9x days, so this wasn't a issue. At the beginning of last year or so distributions began shipping with configurations that enabled software mixing by default.
So when you have sound quality issues nowadays a lot of the time it can be traced back to this software mixing not properly being setup by default.
Now one of the special things about ALSA is that users are able to make a ~/.asoundrc (the ~/ is shorthand for your home directory. The . at the beginning of the name makes it 'hidden') file that can control different sound system behaviors. You can do special things like setup virtual sound cards, or route some sound to one speaker and another application to a different set of speakers and fancy stuff like that.
Well the software mixing is done using a alsa plugin called 'dmix'. It's behavior can be controlled by the ~/.asoundrc file.
So what you can try is to set your own software mixer settings and see if that improves the sound. Sometimes it makes a big difference and some times it doesn't. Sometimes it can actually have a big impact on system performance for things like DVD playback and such.
So in order to find good settings to try out you can do the following.
First off we need a program which we can easily bypass the software mixing and play directly to the sound card. I like Mplayer and it's aviable through the Ubuntu universe repositories. Also you can use alsaplayer, but I think mplayer sounds better.
Then you'll need a decent quality mp3 or flac or ogg file or something like that. Something that sounds nice and is stereo, something that is a ripped from a cdrom.
So the first thing is to open up two terminals.
In the first terminal you run mplayer playing that sound. Just to see what it sounds like.
> mplayer -ao alsaevice=hw=0 *.mp3
that should bypass software mixing. It may complain that the device is in use and refuse to play. If that is true then close out all your sound applications. If you have something that is still using the sound card, but you can't find it then try this command:
> sudo kill $(lsof -t /dev/dsp* /dev/audio* /dev/mixer* /dev/snd/*)
But becarefull with that command. It will close out applications without saving information or being that nice about it. If any Gnome applets or whatnot starts complaning and asking you weither or not they should be restarted, just ignore the dialog screen for now and restart them when your finished.
Once you get mplayer playing directly to the sound card then in the second terminal open up alsamixer
> alsamixer
Alsamixer is a special mixing application that reflects the actual mixing controls for your sound card. Gnome mixers, for example, have a sort of abstracted view, but alsamixer shows everything. The important mixing controls are things like 'Front', 'PCM', 'Mixer', 'Main' and such things. Most of the mixing controls will have little to no effect, but other ones will affect playback. So you want the sound mixers to be about 80% or so torwards maximum. To high and they will distort and cause sound qualities sometimes, so you want to have them kinda evened out. It may take some playing around.
At this point if it still sounds crappy then it's definately driver issues and it's not worth going any further.
If it sounds good at this point then you can configure dmix to make all sound applications have their sound mixed to match that good sounding one.
To do that you check out files in /proc/asound directory while the application is playing. It will have information about settings on the sound cards and what sound formats are currently playing.
So while mplayer is playing run this command:
> cat $(find /proc/asound | grep hw)
This is what I get with my onboard sound card:
$ cat $(find /proc/asound/|grep hw )
closed
closed
closed
closed
closed
closed
closed
access: RW_INTERLEAVED
format: S16_LE
subformat: STD
channels: 2
rate: 44100 (44100/1)
period_size: 1024
buffer_size: 16384
tick_time: 4000
So with that information you make your ~/.asoundrc file.
Mine would look like:
pcm.!default {
type plug
slave.pcm "dmixed"
}
pcm.dmixed {
type dmix
ipc_key 1024
slave {
pcm "hw:0,0"
period_time 0
period_size 1024
buffer_size 16384
rate 44100
}
bindings {
0 0
1 1
}
}
ctl.!default {
type hw
card 0
}
pcm.!dsp0 {
type plug
slave.pcm "dmixed"
}
Just open up the file using gedit and copy and paste that into there and put in your own matching values.
> gedit ~/.asoundrc
Now go and play your normal applications and see if they sound nice. Make sure that they are configured to use 'alsa'.
For old OSS applications that do not have alsa support you can sometimes run them using the aoss application. It's aviable witht he alsa-oss package. You go like this:
> aoss realplayer
That's solved sound issues for me a couple times. It even solved a pretty serious dvd performance issue with my laptop.
If you have problems with that configuration then just delete the file or copy it to a different name.
This is one of those things that is easy to do, but tricky to do the first couple times. You may still have lingering issues, but this should get most of the sound quality issues if it works.
I know my onboard audio is supported and realtek has drivers that it updates pretty often, the ac97 drivers. I downloaded them and tried to install them and i think i did , but i have no idea how to check which drivers im using.
That's usually not recommended route. Sometimes it works, but generally the vendors drivers are worse then the Linux kernel-supplied drivers. It's a bit opposite for Linux then it is Windows. Sometimes it's nessicary though.
But were did you get them from?
They may be OSS drivers and then you'll need to configure your system to disable the alsa drivers and use OSS instead. Sometimes some people just need to use OSS to get things working correctly although in most respects Alsa is superior... which is why OSS is still around.
Im very close to sticking with ubuntu this time cause i fell inlove with beryl and everything with the exception of some minor probs works great.
can someone help me ?
I hope you get it going well also.
You can find more information about this stuff at
http://alsa.opensrc.org/Main_Page if you'd like.
Sometimes they have decent tips...
http://alsa.opensrc.org/Realtek_ALC861
http://alsa.opensrc.org/Realtek_ALC950