From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) by finch.gentoo.org (Postfix) with ESMTP id AE481138CA2 for ; Thu, 16 Apr 2015 01:32:46 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id B753EE08A8; Thu, 16 Apr 2015 01:32:35 +0000 (UTC) Received: from cdptpa-oedge-vip.email.rr.com (cdptpa-outbound-snat.email.rr.com [107.14.166.232]) by pigeon.gentoo.org (Postfix) with ESMTP id 99682E084E for ; Thu, 16 Apr 2015 01:32:34 +0000 (UTC) Received: from [142.196.200.180] ([142.196.200.180:44162] helo=navi.localnet) by cdptpa-oedge02 (envelope-from ) (ecelerity 3.5.0.35861 r(Momo-dev:tip)) with ESMTP id 32/D2-04287-2311F255; Thu, 16 Apr 2015 01:32:34 +0000 From: Fernando Rodriguez To: gentoo-user@lists.gentoo.org Subject: Re: [gentoo-user] beep Date: Wed, 15 Apr 2015 21:31:14 -0400 Message-ID: <8468931.9K0bS2Jh0h@navi> User-Agent: KMail/4.14.3 (Linux/3.19.3; KDE/4.14.3; x86_64; ; ) In-Reply-To: <87h9sie4ao.fsf@heimdali.yagibdah.de> References: <87h9sie4ao.fsf@heimdali.yagibdah.de> Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-user@lists.gentoo.org Reply-to: gentoo-user@lists.gentoo.org MIME-Version: 1.0 Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="us-ascii" X-RR-Connecting-IP: 107.14.168.130:25 X-Cloudmark-Score: 0 X-Archives-Salt: eab78c67-fb32-41e4-9b62-dc10581a3717 X-Archives-Hash: 5e1fcaceac411a44c07b947cfb60a8a2 On Wednesday, April 15, 2015 12:25:03 AM lee wrote: > > Hi, > > when the pcspkr module (or how it's called; I haven't compiled atm) is > loaded, somehow the built-in speaker is used to sometimes beep. There > also seems to be the option to play this beep via the sound card --- > which usually sounds nicer. > > How is this done? Do I need to load a different module for that, or > does it require to use some sort of additional software? If you mean how to configure the kernel for it then just load the right module. I remember seeing a "PC Speaker Emulation" or similar module but I can't find it now so it may be gone. Anyways, this only applies to the console (VT). Software just writes the BEL character (0x07) to it's terminal (stdout) to play a beep. You can also open "/dev/console" directly and play this character or use ioctl calls to play sounds with different frequencies and duration but this requires root privileges. Modern desktop terminal emulators will already be using the sound card to play the BEL character. On KDE for example you can choose any sound file to play or just show a notification. -- Fernando Rodriguez