From owner-freebsd-questions@FreeBSD.ORG Mon Sep 14 17:34:22 2009 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 A00561065672 for ; Mon, 14 Sep 2009 17:34:22 +0000 (UTC) (envelope-from rsmith@xs4all.nl) Received: from smtp-vbr17.xs4all.nl (smtp-vbr17.xs4all.nl [194.109.24.37]) by mx1.freebsd.org (Postfix) with ESMTP id 36C178FC13 for ; Mon, 14 Sep 2009 17:34:21 +0000 (UTC) Received: from slackbox.xs4all.nl (slackbox.xs4all.nl [213.84.242.160]) by smtp-vbr17.xs4all.nl (8.13.8/8.13.8) with ESMTP id n8EHYKrE066711; Mon, 14 Sep 2009 19:34:20 +0200 (CEST) (envelope-from rsmith@xs4all.nl) Received: by slackbox.xs4all.nl (Postfix, from userid 1001) id 60FAEBAAA; Mon, 14 Sep 2009 19:34:20 +0200 (CEST) Date: Mon, 14 Sep 2009 19:34:20 +0200 From: Roland Smith To: Eitan Adler Message-ID: <20090914173420.GB69286@slackbox.xs4all.nl> References: MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="KFztAG8eRSV9hGtP" Content-Disposition: inline In-Reply-To: X-GPG-Fingerprint: 1A2B 477F 9970 BA3C 2914 B7CE 1277 EFB0 C321 A725 X-GPG-Key: http://www.xs4all.nl/~rsmith/pubkey.txt X-GPG-Notice: If this message is not signed, don't assume I sent it! User-Agent: Mutt/1.5.20 (2009-06-14) X-Virus-Scanned: by XS4ALL Virus Scanner Cc: freebsd-questions@freebsd.org Subject: Re: rebinding keys to functions 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: Mon, 14 Sep 2009 17:34:22 -0000 --KFztAG8eRSV9hGtP Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Mon, Sep 14, 2009 at 04:52:56PM +0000, Eitan Adler wrote: > My laptop has a bunch of volume-up/down/mute internet/mail/etc keys. > How do I map each of them to run a specific shell command when pressed? That depends on a couple of things (assuming you're running the X window system, I don't know if it is even possible on the console). First you have to make sure that you actually can see the key signals. In X you can test that with xev(1). How you can bind keypresses to commands in X depends on the window manager = or desktop environment you are using. See the revelant documentation. On my laptop (centrino 2 platform, PM 45 chipset), using Fn combination wor= ks to change speaker volume and screen brightness, but this is done outside the OS. The X server doesn't even 'see' those keypresses. Roland --=20 R.F.Smith http://www.xs4all.nl/~rsmith/ [plain text _non-HTML_ PGP/GnuPG encrypted/signed email much appreciated] pgp: 1A2B 477F 9970 BA3C 2914 B7CE 1277 EFB0 C321 A725 (KeyID: C321A725) --KFztAG8eRSV9hGtP Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.13 (FreeBSD) iEYEARECAAYFAkqufpwACgkQEnfvsMMhpyVE9gCgiJqVxYyCy07F0CsHYUcTbH/9 xF4AoJprK1gG+bk3KuU26Vur8szLa5vK =3oAu -----END PGP SIGNATURE----- --KFztAG8eRSV9hGtP--