Tiny Core Linux

Tiny Core Extensions => TCE Tips & Tricks => Topic started by: Zero on August 19, 2012, 12:55:24 PM

Title: Persistent alsa audio levels between boots
Post by: Zero on August 19, 2012, 12:55:24 PM
Could find little info on this topic by searching the forum. This took me quite a while to resolve. Hope to save someone else some grief. The problem I faced was default alsamixer levels were WAY too low for my Dell L400.  Combed through this wiki  http://wiki.tinycorelinux.net/wiki:setting_up_sound (http://wiki.tinycorelinux.net/wiki:setting_up_sound)  but ran into a couple of walls. Here's what I did to get alsa mixer levels to persist.

* To get sound working at all I had to install alsa.tcz OnBoot. (To get Skype audio working I also had to add alsa-oss.tcz OnBoot.)
* I ran sudo alsaconf but sound was already working at that point so it was probably moot.
* Per the wiki, using editor I then added the following lines to /opt/.filetool.lst

opt/alsa
etc/modprobe.conf
etc/asound.state


Problem was at shutdown there was a backup error because etc/asound.state does not exist at this point and my sound settings were not being restored. Reading further down the wiki I found the command alsactl store but it needs to be run as root. So I ran sudo alsactl store which then creates /usr/local/etc/asound.state not /etc/asound.state. Still getting the file not found backup error I changed the last line of /opt/.filetool.lst to usr/local/etc/asound.state minus the preceding forward slash.
* In terminal I ran sudo editor, opened /opt/bootlocal.sh and added alsactl restore at the end. Worthy of note, I did NOT have to add to bootlocal.sh

/bin/sleep 5
/usr/local/etc/init.d/alsasound start

Now my new default mixer levels are restored at each boot. To change default values now I just set the desired levels, open a terminal and do sudo alsactl store and done.

Z
Title: Re: Persistent alsa audio levels between boots
Post by: tinypoodle on August 19, 2012, 01:30:51 PM
* To get sound working at all I had to install alsa.tcz OnBoot. (To get Skype audio working I also had to add alsa-oss.tcz OnBoot.)

Which version of skype are you using?

alsa-oss should not be required for a recent alsa version of skype.

Hint: You can use the "-f" parameter of alsactl to specify a filename (e.g. to save multiple configurations).
Title: Re: Persistent alsa audio levels between boots
Post by: Zero on August 19, 2012, 02:22:46 PM
I am using the latest and greatest Skype, 4.0.0.8, across all my linux machines, most of which are Xubuntu. Believe me when I say alsa-oss was required on my Dell L400, Cirrus Logic CS4281 audio.

I found the -f parameter later on much further down the wiki page. But, I now have it fixed without using that parameter. I subscribe to the philosophy "If it ain't broke, don't 'fix' it."  ;D
Title: Re: Persistent alsa audio levels between boots
Post by: dlrider on October 03, 2012, 04:33:34 PM
Now my new default mixer levels are restored at each boot.
Very good!  Finally have my levels consistent between boots... except the channel lock (left/right).  How do I keep the pair locked together?   Thank you.
D.
Title: Re: Persistent alsa audio levels between boots
Post by: aus9 on October 03, 2012, 04:53:58 PM
hi

Quote
Problem was at shutdown there was a backup error because etc/asound.state does not exist at this point and my sound settings were not being restored

The wiki suggests that under Alsasound
Quote
Create a sound mixer level config file (= /etc/asound.state) by running
Code: [Select]
sudo alsactl store
Maybe the wiki needs improving, I will look at providing a summary or checklist before reboot.
I have split wiki into an OSS page and ALSA. will improve it in the fullness of time.

some issues for mixer levels should be resolved with the asound.state but we could add a `.asoundrc but I have yet to test.
Title: Re: Persistent alsa audio levels between boots
Post by: Rich on October 03, 2012, 05:32:59 PM
Hi aus9
The alsa extension was updated since that Wiki was written. See the alsa info file for more details.
Title: Re: Persistent alsa audio levels between boots
Post by: aus9 on October 03, 2012, 11:32:53 PM
Rich

I hope Zero does not mind a slight hijack. I have started to do wiki edits, OSS being the easiest and will get around to Alsa after I read maintainer's info etc.

If any newbie reads this thread and then the wikis and does not understand it, feel free to pm me please. But give me a few days to make it up-to-date. The wiki is meant to be read by newbies so I might have cull ?

Zero
I am not suggesting you try alternatives to skype but assume you know about them?

good luck

EDIT

OSS wiki is now kinda complete
 
Title: Re: Persistent alsa audio levels between boots
Post by: aus9 on October 05, 2012, 04:04:18 AM
dlrider

I have started to update wiki, your answer may lie in the alsamixergui section. Let us know if you understood it, as the wiki is only good if it helps newbies.
Title: Re: Persistent alsa audio levels between boots
Post by: coreplayer2 on October 05, 2012, 10:26:48 AM
Quote
I subscribe to the philosophy "If it ain't broke, don't 'fix' it."

Where's the fun in that??   :p