Discussion:
[xmonad] Extra keyboard
Jean-Baptiste Mestelan
2015-05-06 05:46:38 UTC
Permalink
Hello,


I have a USB numeric keypad lying about, and would like to use its
keys as special shortcuts (like, its Num-6 could simulate
XF86AudioNext...).
How do I tell its key strokes apart from those of the main keyboard?
Is this done at X level?
Would the helpful people on this list provide some pointers, or set me started?

Thanks for attention.

* FWIW, here is dmesg:
[81553.409035] input: USB KB USB KB as
/devices/pci0000:00/0000:00:14.0/usb3/3-3/3-3.4/3-3.4:1.0/0003:1241:1503.0006/input/input31
[81553.409193] hid-generic 0003:1241:1503.0006: input,hidraw2: USB HID
v1.10 Keyboard [USB KB USB KB] on usb-0000:00:14.0-3.4/input0
Brandon Allbery
2015-05-06 13:27:02 UTC
Permalink
Post by Jean-Baptiste Mestelan
I have a USB numeric keypad lying about, and would like to use its
keys as special shortcuts (like, its Num-6 could simulate
XF86AudioNext...).
How do I tell its key strokes apart from those of the main keyboard?
Is this done at X level?
Would the helpful people on this list provide some pointers, or set me started?
You'll need to use the XInput extension (x11-xinput package), as X11 core
only understands a single keyboard so by default all system keyboards are
treated identically and their events mixed into a single event stream.
--
brandon s allbery kf8nh sine nomine associates
***@gmail.com ***@sinenomine.net
unix, openafs, kerberos, infrastructure, xmonad http://sinenomine.net
Jean-Baptiste Mestelan
2015-05-07 13:17:52 UTC
Permalink
Post by Brandon Allbery
You'll need to use the XInput extension (x11-xinput package), as X11 core
only understands a single keyboard so by default all system keyboards are
treated identically and their events mixed into a single event stream.
Many thanks, Brandon; looking into that now.
Daniel Wagner
2015-05-18 00:12:24 UTC
Permalink
Just in case the question was more specific than it needed to be, it's
possible the numeric keypad reports different keys than the "number keys"
at the top of your normal keyboard anyway. X distinguishes between xK_6 and
xK_KP_6. So if you don't normally use the keypad on your main keyboard,
this can be an option.

~d
Post by Jean-Baptiste Mestelan
Hello,
I have a USB numeric keypad lying about, and would like to use its
keys as special shortcuts (like, its Num-6 could simulate
XF86AudioNext...).
How do I tell its key strokes apart from those of the main keyboard?
Is this done at X level?
Would the helpful people on this list provide some pointers, or set me started?
Thanks for attention.
[81553.409035] input: USB KB USB KB as
/devices/pci0000:00/0000:00:14.0/usb3/3-3/3-3.4/3-3.4:1.0/0003:1241:1503.0006/input/input31
[81553.409193] hid-generic 0003:1241:1503.0006: input,hidraw2: USB HID
v1.10 Keyboard [USB KB USB KB] on usb-0000:00:14.0-3.4/input0
_______________________________________________
xmonad mailing list
http://mail.haskell.org/cgi-bin/mailman/listinfo/xmonad
Jean-Baptiste Mestelan
2015-06-04 08:40:31 UTC
Permalink
Post by Daniel Wagner
Just in case the question was more specific than it needed to be, it's
possible the numeric keypad reports different keys than the "number keys" at
the top of your normal keyboard anyway. X distinguishes between xK_6 and
xK_KP_6. So if you don't normally use the keypad on your main keyboard, this
can be an option.
Many thanks, Daniel, for your notice.
You are quite right that my numeric keypad reports distinct keys, and
I should have realized that, since they do not toggle workspaces.
So i might even get away with a single keyboard.

Thanks again (and sorry for the late reply).

Continue reading on narkive:
Loading...