From owner-freebsd-questions@FreeBSD.ORG Mon Oct 7 12:46:54 2013 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTP id B49E3455 for ; Mon, 7 Oct 2013 12:46:54 +0000 (UTC) (envelope-from frank2@fjl.co.uk) Received: from bs1.fjl.org.uk (bs1.fjl.org.uk [84.45.41.196]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 18AB020C1 for ; Mon, 7 Oct 2013 12:46:53 +0000 (UTC) Received: from [192.168.1.35] (mux.fjl.org.uk [62.3.120.246]) (authenticated bits=0) by bs1.fjl.org.uk (8.14.4/8.14.4) with ESMTP id r97CkppR053151 (version=TLSv1/SSLv3 cipher=DHE-DSS-CAMELLIA256-SHA bits=256 verify=NO) for ; Mon, 7 Oct 2013 13:46:51 +0100 (BST) (envelope-from frank2@fjl.co.uk) Message-ID: <5252AD3D.7070703@fjl.co.uk> Date: Mon, 07 Oct 2013 13:46:53 +0100 From: Frank Leonhardt User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:17.0) Gecko/20130801 Thunderbird/17.0.8 MIME-Version: 1.0 To: "freebsd-questions@freebsd.org" Subject: Re: How do I ring a bell? References: <52529CFF.9030105@fjl.co.uk> In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Content-Filtered-By: Mailman/MimeDel 2.1.14 X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 07 Oct 2013 12:46:54 -0000 On 07/10/2013 13:06, Peter Boosten wrote: > > On 7 okt. 2013, at 13:37, Frank Leonhardt > wrote: > >> In the good'ol days I could make UNIX ring a bell (literally) by >> sending \a to the console TTY (an ASR33 in my case). Now there's an >> electronic synthesised ting or beep from an terminal emulator IF it's >> got a sound card and so on, and an IBM-PC had a beep routine in the BIOS. >> >> Is there any way to make a noise through the built in "bell" speaker >> found on an IBM PC compatible server box? Writing 007 to the BIOS >> cout routine might do it, but I've realised I haven't got a clue how >> to do that. >> >> I could easily knock up a bit of hardware to go on a serial port (or >> similar) that could be triggered to make a noise, but these things >> have already got the hardware built in and I'm looking to use what >> I've already got. >> >> Thanks, Frank. >> >> P.S. "cdcontrol -f /dev/mycdrom eject" is the best I've come up with >> so far for getting attention. >> >> _______________________________________________ >> freebsd-questions@freebsd.org >> mailing list >> http://lists.freebsd.org/mailman/listinfo/freebsd-questions >> To unsubscribe, send any mail to >> "freebsd-questions-unsubscribe@freebsd.org" > > echo "CTRL-V CTRL-G" should do the trick > Alas, not. The console driver won't ring the BIOS bell on anything I've tried. It might on a desktop with a built-in sound card and speakers, but it won't do anything with the "beep" speaker. It's actually the same solution I mentioned in the first line (\a translates to 007 which is ctrl-G). Then there's the issue of writing it to the console rather than a virtual terminal, but I have a few hacks that'll achieve that part. IIRC there was once a FreeBSD kernel module to drive the PC speaker (through /dev/pcspeaker or similar), but it seems to have gone or I'm confusing it with another BSD (or Linux). No I'm not. /usr/src/sys/dev/speaker/spkr.c(!) I may be close to a solution... Regards, Frank.