From owner-freebsd-questions@FreeBSD.ORG Tue Sep 18 00:27:24 2007 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 6AA1F16A41B for ; Tue, 18 Sep 2007 00:27:24 +0000 (UTC) (envelope-from freebsd@meijome.net) Received: from sigma.octantis.com.au (ns2.octantis.com.au [207.44.189.124]) by mx1.freebsd.org (Postfix) with ESMTP id 20DA113C442 for ; Tue, 18 Sep 2007 00:27:23 +0000 (UTC) (envelope-from freebsd@meijome.net) Received: (qmail 2313 invoked from network); 17 Sep 2007 19:27:14 -0500 Received: from 124-170-67-198.dyn.iinet.net.au (HELO localhost) (124.170.67.198) by sigma.octantis.com.au with (DHE-RSA-AES256-SHA encrypted) SMTP; 17 Sep 2007 19:27:13 -0500 Date: Tue, 18 Sep 2007 10:27:10 +1000 From: Norberto Meijome To: "Harry Doyle" Message-ID: <20070918102710.068465da@localhost> In-Reply-To: <950c85d80709171222o596ef293p75a793d87b45f38b@mail.gmail.com> References: <950c85d80709171222o596ef293p75a793d87b45f38b@mail.gmail.com> X-Mailer: Claws Mail 3.0.0 (GTK+ 2.10.14; i386-portbld-freebsd6.2) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Cc: freebsd-questions@freebsd.org Subject: Re: mixer levels on boot X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 18 Sep 2007 00:27:24 -0000 On Mon, 17 Sep 2007 16:22:03 -0300 "Harry Doyle" wrote: > hello everyone, > i am running a freebsd server to stream my local campus station's radio > broadcast to the net. i am using the stock ac97 audio, and using a little > script in /usr/local/etc/rc.d which uses kldload to load the driver. it'd be better to simply add to /boot/loader.conf.local (or loader.conf , i prefer to have it clearly defined) {DRIVER}_load="YES" eg, for my Intel HDA i have snd_hda_load="YES" > > i have to issue mixer rec -83 to get the audio down to a decent level (very > hot coming out of the mixer but i can't change that for other reasons). i > have tried to script this mixer command into startup by putting a sleep > command and then the mixer command, and also by using the /boot/boot.hints > file. > > however whenever i reboot the machine the mixer command always shows the > default level of 90 which clips pretty hard. either 1) have a script that sets your levels . mine is saved by the OS,, but sometimes i need to do it by hand, so i use this script: [betom@ayiin] [Tue Sep 18 10:23:27 2007] /usr/home/betom $ cat bin/set_mixer.sh #!/bin/sh ## Feedback fixed!!! mic == 0 mixer vol 86:86 pcm 86:86 speaker 49:49 mic 0:0 cd 40:40 rec 100:100 =rec mic -- of course, your device may be different, so adjust accordingly. 2) to save the values, check /etc/rc.d/mixer. mixer_save is called on stop, so a) set your levels b) add to /etc/rc.conf mixer_enable="YES" # Run the sound mixer. c) run /etc/rc.d/mixer stop d) reboot + verify they are set to the right thing. In theory, they should be saved everytime to reboot.. ( i just realised i dont actually have that line in rc.conf...but my levels are kept across reboots..so all is good... :) > > also, the sound driver doesn't seem to load until around 2 minutes after i > can log into a fresh boot (not a problem, just some extra info). how can i > script my default rec level on boot? use /boot/loader.conf.local _________________________ {Beto|Norberto|Numard} Meijome "The freethinking of one age is the common sense of the next." Matthew Arnold I speak for myself, not my employer. Contents may be hot. Slippery when wet. Reading disclaimers makes you go blind. Writing them is worse. You have been Warned.