linux-input.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Bastien Nocera <hadess@hadess.net>
To: linux-input@vger.kernel.org
Subject: Trying to remap a wrongly labelled key
Date: Thu, 22 Jan 2009 16:08:34 +0000	[thread overview]
Message-ID: <1232640514.3330.665.camel@cookie.hadess.net> (raw)

Heya,

This Dell keyboard has a "media" key, with a music note on it. The
problem is that it's KEY_CONFIG I get instead of KEY_MEDIA.

So I'm trying to fix the problem in user-space. This is one of the
snippets I've tried to use:

        int codes[2];
        codes[0] = 0x183;
        codes[1] = KEY_MEDIA;
        if (ioctl (fd, EVIOCSKEYCODE, codes) < 0)
                perror ("Set keycode failed");

I inserted that into evtest.

# ./evtest /dev/input/event6 
Input driver version is 1.0.0
Input device ID: bus 0x3 vendor 0x413c product 0x2010 version 0x110
Input device name: "Dell Dell USB Keyboard Hub"
Supported events:
  Event type 0 (Sync)
  Event type 1 (Key)
<snip>
    Event code 171 (Config)
<snip>
Set keycode failed: Invalid argument

So there's a key for which the scancode corresponds to KEY_CONFIG. It
should be 0x183 according to the HUT. but it doesn't want to work for
me...

I'm using 2.6.27.9

Cheers


             reply	other threads:[~2009-01-22 16:08 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-01-22 16:08 Bastien Nocera [this message]
2009-02-02 12:32 ` Trying to remap a wrongly labelled key Jiri Kosina
2009-02-04 12:52   ` Bastien Nocera

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1232640514.3330.665.camel@cookie.hadess.net \
    --to=hadess@hadess.net \
    --cc=linux-input@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).