Date: Sun, 1 May 2005 13:18:15 +0200 From: Pawel Jakub Dawidek <pjd@FreeBSD.org> To: Sarunas Vancevicius <svan@redbrick.dcu.ie> Cc: mobile@freebsd.org Subject: Re: Out of battery indicator. Message-ID: <20050501111815.GF837@darkness.comp.waw.pl> In-Reply-To: <20050308230736.GA5040@carbon.redbrick.dcu.ie> References: <20050305192153.GA20692@genius.tao.org.uk> <20050308230736.GA5040@carbon.redbrick.dcu.ie>
next in thread | previous in thread | raw e-mail | index | archive | help
--oEj3/8+YnogYHQRs Content-Type: text/plain; charset=iso-8859-2 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Tue, Mar 08, 2005 at 11:07:36PM +0000, Sarunas Vancevicius wrote: +> On 19:21, Sat 05 Mar 05, Josef Karthauser wrote: +> > Does anyone have a solution to running out of battery using ACPI (5.3?= ). +> > I keep forgetting to plug in my power supply and the machine dies rath= er +> > suddenly without beeping or giving me any warning that it was out of +> > battery. +> >=20 +> > Any ideas? I would have thought that this was an O/S task rather than= a +> > third party app task. +> >=20 +> > Joe +>=20 +> Hi All, +>=20 +> For rather complex solution: +>=20 +> # kldload speaker +> # chmod 660 /dev/speaker +>=20 +> Checkout source code for battd utility in DragonFly +> (http://dragonflybsd.org/cvsweb/src/usr.sbin/battd/). Compile, install +> and run it with something like: +>=20 +> $ battd -p 10 -e $HOME/bin/beep_speaker +>=20 +> And where $HOME/bin/beep_speaker: +>=20 +> #/bin/sh +> TUNE=3D"l2b.f+.p16a.c+.p l4mn<b.>e8a2mspg+e8c+f+8b2" +> /bin/echo $TUNE > /dev/speaker +>=20 +> Which will play "opening bars of the theme from Star Trek Classic" when +> the battery will reach approximately 10%. There are more tunes in +> src/usr.sbin/spkrtest/spkrtest.sh, and you can always make your own ;-). +>=20 +> A long string of 'A's will produce unpleasant beeping, which will remind +> you to turn on turn on your power supply :-). We should probably integrate this functionality into powerd(8). --=20 Pawel Jakub Dawidek http://www.wheel.pl pjd@FreeBSD.org http://www.FreeBSD.org FreeBSD committer Am I Evil? Yes, I Am! --oEj3/8+YnogYHQRs Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.2.4 (FreeBSD) iD8DBQFCdLr3ForvXbEpPzQRAo0SAJ9ZecwwjNYSAneQnqXYRls62WkzvACg14xq uFalJ5gxF/+NVM5K7B6kjQI= =Bgiw -----END PGP SIGNATURE----- --oEj3/8+YnogYHQRs--
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20050501111815.GF837>