http://www.helplinux.ru/wiki/en:kb:ubuntu-plantronics
Perequisites
Scancodes can be discovered by evtest:
sudo evtest
Keynames can be discovered in linux/input.h:
less /usr/src/linux-headers-$(uname -r)/include/uapi/linux/input.hVendor ID and Product ID can be discovered by lsusb:
lsusb | grep -i plantronicsUbuntu 13.10 (64-bit only), Ubuntu 14.04
Create file /etc/udev/rules.d/59-plantronics.rules with the following content:
ACTION!="add|change", GOTO="xorg_plantronics_end" KERNEL!="event*", GOTO="xorg_plantronics_end" SUBSYSTEMS=="usb", ENV{ID_BUS}=="", IMPORT{builtin}="usb_id" ENV{ID_VENDOR_ID}=="047f", ENV{ID_MODEL_ID}=="c013", ENV{ID_INPUT_KEY}="1", ENV{ID_INPUT_KEYBOARD}="1" LABEL="xorg_plantronics_end"Create file /etc/udev/hwdb.d/60-keyboard.hwdb with the following content:
# Plantronics .Audio 648 USB keyboard:usb:v047FpC013* KEYBOARD_KEY_ffa000b1=volumeup KEYBOARD_KEY_ffa000b2=volumedown KEYBOARD_KEY_ffa000b5=micmute KEYBOARD_KEY_ffa000b7=phone KEYBOARD_KEY_ffa000ab=unknownReload udev rules:
sudo udevadm hwdb --update sudo udevadm control --reload Unplug and plug again the usb device. Enjoy!
===
/dev/input/by-id/usb-USBest_tec
evtest /dev/input/eventX
xinput list
xinput test 10
=
lsusb -t
get DEV info for usb device interested in then:
lsusb -vv -s 6
other?modinfo usbhid
Identify USB Driver. Ubuntu, Debian, Mint, CentOS, Fedora & all Linux distro
“The API provides an easy method to enumerate HID devices attached to the system, and easy access to the functionality of the most commonly used HID functions including transfer of Input, Output, and Feature Reports”
http://www.signal11.us/oss/hidapi/
https://github.com/signal11/hidapi