From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from pigeon.gentoo.org ([208.92.234.80] helo=lists.gentoo.org) by finch.gentoo.org with esmtp (Exim 4.60) (envelope-from ) id 1S8ae2-0006Ty-Qa for garchives@archives.gentoo.org; Fri, 16 Mar 2012 17:08:57 +0000 Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 160A9E0CEB; Fri, 16 Mar 2012 17:08:36 +0000 (UTC) Received: from mail-wi0-f175.google.com (mail-wi0-f175.google.com [209.85.212.175]) by pigeon.gentoo.org (Postfix) with ESMTP id D2CE9E0CD1 for ; Fri, 16 Mar 2012 17:07:36 +0000 (UTC) Received: by wibhn6 with SMTP id hn6so1000682wib.10 for ; Fri, 16 Mar 2012 10:07:36 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type:content-transfer-encoding; bh=HoNuYMOvwHkzoDIiUYuQfn3WmNyxVLTCNqeKRcDqB7c=; b=YevHFOMJiCLXwV5umRC6IxplidJdQMxlS+B1JBkJ9ULtAau8HIv5WbcCYCeoruWCBW ZHf/t497KTsDta1FH1ikRVd3uD/RIA8Q6Bdg3Ulx3xusC4CaaEdR0oXOvyA4cHyta9Yd 7dPtVCF2gkDmg7lWgBjZo3n2KEMDURdARqwZkDqDwp777a58i9seR4dwK4I9FcVj8nwA jM8lbuwK0Be7LIT3+R9r84pxB1br0Y8zzNz4CuIiUYirySRenRKtE0D6iLBy6Pj32IO5 vjP6xk+iQ9+vKSblZ8lgoqMqleYSo99icAOJSQnHsSGfhiu8Mqm5tRQgHCiq76oytRdd F3Yg== 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 Received: by 10.180.83.42 with SMTP id n10mr142288wiy.9.1331917656017; Fri, 16 Mar 2012 10:07:36 -0700 (PDT) Received: by 10.223.8.68 with HTTP; Fri, 16 Mar 2012 10:07:35 -0700 (PDT) In-Reply-To: <20120313122731.GC6173@ksp.sk> References: <20120313122731.GC6173@ksp.sk> Date: Fri, 16 Mar 2012 10:07:35 -0700 Message-ID: Subject: Re: [gentoo-user] How are Fn-F# ACPI events mapped? From: Mark Knecht To: gentoo-user@lists.gentoo.org Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Archives-Salt: de4ef3c5-158d-4ffc-8282-e7bd120a397f X-Archives-Hash: 45412d2b77cdd990033a89e96c1c31c6 On Tue, Mar 13, 2012 at 5:27 AM, YoYo Siska wrote: > On Sun, Mar 11, 2012 at 03:23:28PM -0700, Mark Knecht wrote: >> Hi, >> =C2=A0 =C2=A0I'm trying to figure out how my Asus laptop maps function k= ey >> events. This is being driven by an emerge message telling me that the >> acpi4asus package is being obsoleted and removed in 30 days and >> replaced by an in-kernel driver. I've removed the package and rebuilt >> my kernels to use this driver, and for vanilla-sources-3.2.7 the >> results are similar as with the acpi4asus package. > > don't know anything about the assus packages/drivers, but the general > direction in all such drivers is to move these things where they belong: > to the input subsystem, so my guess is the new driver doesn't produce > acpi events, but insted create a "input device" and produce key > press/release events on that device... > > (note that sleep / hibernate actions are usually still reported also > throgh acpi, because some programs expect them to come from there, that > would explaing your Fn-F1/sleep working) > > to test this, just run as root on the linux console (not in a termnal in > X): > > showkey -s > > and then pres the keys (ie Fn-F4,) to stop showkeys, just don't press > anything for 10 seconds... > if you see numbers appearing after each keypress / release, then the key > directly generates keyboard ivents =C2=A0and its possible you will see th= em > directly in X, for that jus run (now under X) > > xev > > and (the window that appears must have focus / be active) press the keys > again, xev will print the X keycodes/keysyms to its output... > if you see reasonable names there, then you should be able to map those > keys in the programs you are using (ie global hotkeys in kde, etc...) > note however that qt/kde doesn't recognise some of the more exotic > keysyms... =C2=A0(in my case XF86TouchpadToggle produced by Fn-F8 on > thinkpads ;) > > if you can see the key in showkey -s =C2=A0but not in xev, the problem mi= ght > be in kernel keyboard map (though i'm not sure if the x's evdev driver > uses that) or in the evdev driver not mapping that key > > basically the kernel driver reports scan codes (what showkey -s shows), > kernel translates that to keycodes (showkey -k to see them) and then X's > input driver (ie evdev) translates those to the X keycodes X server > again trasnlates them to keysym-s.... > > yoyo > Hi, Sorry about the late reply. I messed with this a few days ago but never wrote to say thanks. My bad. Basic outcome - there seemed to be three things I learned: 1) The basic message architecture, thanks to your post. Thanks for that. 2) There is some problem with vanilla-sources-3.2.9 which is apparently fixed in 3.2.10. Thanks to kernel devs I suppose for that. Almost all the function keys now produce some sort of message in acpi_listen, showkey & xev. 3) The function I seem to be missing at this point is being able to actually control the brightness of keyboard backlights. I can do this in Windows but not in Linux. However I don't know yet if Linux even has a driver with that capability so I'll have to spend some time looking for that over the weekend. Again, thanks for the response. It was quite helpful. Cheers, Mark