[LINUX] Generic HID Remote Driver for XBMC (Drivers for XBMC on Linux and XBMC Live)

  Thread Rating:
  • 7 Votes - 5 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Post Reply
thevillain9 Offline
Junior Member
Posts: 5
Joined: Jan 2011
Reputation: 0
Location: NYC
Post: #161
I want to make some changes to my key mapping file, but after exiting xbmc, I see the following lines open in the terminal:

Found HID Device
Opened HID interface on /dev/hidraw2
Opened HID interface on /dev/hidraw3
Generic USB mapper driver setup

I added the loading of the map file in my /etc/rc.local/ and now I can't seem to get into the terminal prompt. Any ideas? Thanks.
find quote
UsagiYojimbo Offline
Member
Posts: 83
Joined: Feb 2010
Reputation: 1
Location: Debrecen, Hungary
Post: #162
thevillain9 Wrote:I added the loading of the map file in my /etc/rc.local/ and now I can't seem to get into the terminal prompt. Any ideas? Thanks.

Did you place a space and an ampersand (&) at the end of the command? Nerd
EG: /path/hidmapper -options ... &
find quote
leorik Offline
Senior Member
Posts: 110
Joined: Jan 2009
Reputation: 0
Post: #163
Has anyone got this to work in 11.04 with Jetway IR Remote? I'm getting the same error as everyone else. It lists the device, but won't work from there.


I see somebody posted the jetway codes from before. Those don't work in the xbmc keymap file by chance, do they?
find quote
rapalax Offline
Junior Member
Posts: 24
Joined: Dec 2010
Reputation: 0
Post: #164
I was able to get hid_mapper to work on 11.04 on my jetway by running as root explicitly. Sudoing didn't work for some reason.

Now i just need to fine a nice map.
(This post was last modified: 2011-10-07 05:37 by rapalax.)
find quote
Bradburts Offline
Junior Member
Posts: 1
Joined: Oct 2011
Reputation: 0
Post: #165
Hi,
Thanks for writting this great utility. Have been pullin my hair out trying to get all buttons on http://www.amazon.co.uk/gp/product/B001M56DI0 working.
The remote works okish on Ubuntu Server 11.04 but the volume up does not seem to translate to a keycode.
I can see IR codes using cat /dev/input/event4 | hexdump though.

Being a linux newbie, is this utility going to work on Ubuntu Server?
I aim to use your utility to fix the missing Volume Up and other 'missing' media buttons so that I can control a headless music player.
I have gnome-core installed for VNC Server but don't usually start the server and will eventually drop that part of my install.

I can see problems with my setup & this guide, I don't have /usr/share/X11/xorg.conf.d/ for example & would really like to know how far I this will run before I hit another dead end.
(This post was last modified: 2011-10-13 18:05 by Bradburts.)
find quote
dodddummy Offline
Junior Member
Posts: 1
Joined: Dec 2011
Reputation: 0
Post: #166
Bob,
Nice work. This make many of my old devices usable.

Had enough success I thought I'd try it on a device I'd given up on, Fisher Price Digital Studio. So far this maps all of the buttons but they repeat and the learn tool sees changes in the pen but I can't figure out how to map them. But the key presses for this thing has 4 more bytes. For the button presses the are all ff but for the mouse movements the numbers vary. I suppose those are to describe the movement of the pointer.

I'm hopeful you or someone else can point me in the right direction to being able to map the pen movements, too.

Here is map for the buttons
# Power Button

47100000000002ffffffff:KEY_W

# Print

47000000040002ffffffff:KEY_PRINT

# Home

47000004000002ffffffff:KEY_HOME

# White

47010000000002ffffffff:KEY_A

# Black

47000000000202ffffffff:KEY_B

# Brown

47000000020002ffffffff:KEY_C

# Purple

47000002000002ffffffff:KEY_D

# Blue

47000200000002ffffffff:KEY_E

# Green

47020000000002ffffffff:KEY_F

# Yellow

47000000000102ffffffff:KEY_G

# Orange

47000000010002ffffffff:KEY_H

# Red

47000100000002ffffffff:KEY_I

# Color Wheel

47000001000002ffffffff:KEY_J

# Landscape Picture

47000800000002ffffffff:KEY_K

# Stamp Tool

47080000000002ffffffff:KEY_L

# Paint Bucket Tool

47000000000402ffffffff:KEY_M

# Redo or goback?

47040000000002ffffffff:KEY_N

# Star Burst

47000000000802ffffffff:KEY_O

# Shooting Star

47000000080002ffffffff:KEY_P

# ABCD

47000008000002ffffffff:KEY_Q

# Pencil

47001000000002ffffffff:KEY_R

# Paint Brush

47000010000002ffffffff:KEY_S

# Spray Can

47000000100002ffffffff:KEY_T

# Eraser

47000000001002ffffffff:KEY_U

# Toggle button

47000000000003ffffffff:KEY_V

And here is a sample of the learn for the pen movements. 47 00 00 00 00 00 02 is when the pressure tip is not pressed and 47 00 00 00 00 00 00 is when it is pressed.

47 00 00 00 00 00 02 7c 02 a6 01
47 00 00 00 00 00 02 6d 02 a3 01
47 00 00 00 00 00 02 56 02 b0 01
47 00 00 00 00 00 02 49 02 b3 01
47 00 00 00 00 00 02 38 02 b8 01
47 00 00 00 00 00 02 29 02 c0 01
47 00 00 00 00 00 00 08 02 d0 01
47 00 00 00 00 00 00 de 01 e2 01
47 00 00 00 00 00 00 af 01 f0 01
47 00 00 00 00 00 00 87 01 f4 01
47 00 00 00 00 00 00 66 01 eb 01
47 00 00 00 00 00 00 54 01 d2 01
47 00 00 00 00 00 00 4e 01 ac 01
47 00 00 00 00 00 00 54 01 80 01
47 00 00 00 00 00 00 5b 01 55 01
47 00 00 00 00 00 00 6d 01 37 01
47 00 00 00 00 00 00 85 01 28 01
47 00 00 00 00 00 00 97 01 29 01

jason@jason-lenovo:~$ lsusb
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 002 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 001 Device 002: ID 8087:0020 Intel Corp. Integrated Rate Matching Hub
Bus 002 Device 002: ID 8087:0020 Intel Corp. Integrated Rate Matching Hub
Bus 002 Device 018: ID 0813:1006 Mattel, Inc.
Bus 002 Device 016: ID 093a:2510 Pixart Imaging, Inc. Optical Mouse
Bus 002 Device 005: ID 04f2:b1c1 Chicony Electronics Co., Ltd

udevadm info --attribute-walk --name=/dev/hidraw0
looking at device '/devices/pci0000:00/0000:00:1d.0/usb2/2-1/2-1.2/2-1.2:1.0/0003:0813:1006.000F/hidraw/hidraw0':
KERNEL=="hidraw0"
SUBSYSTEM=="hidraw"
DRIVER==""

looking at parent device '/devices/pci0000:00/0000:00:1d.0/usb2/2-1/2-1.2/2-1.2:1.0/0003:0813:1006.000F':
KERNELS=="0003:0813:1006.000F"
SUBSYSTEMS=="hid"
DRIVERS=="generic-usb"

looking at parent device '/devices/pci0000:00/0000:00:1d.0/usb2/2-1/2-1.2/2-1.2:1.0':
KERNELS=="2-1.2:1.0"
SUBSYSTEMS=="usb"
DRIVERS=="usbhid"
ATTRS{bInterfaceNumber}=="00"
ATTRS{bAlternateSetting}==" 0"
ATTRS{bNumEndpoints}=="01"
ATTRS{bInterfaceClass}=="03"
ATTRS{bInterfaceSubClass}=="00"
ATTRS{bInterfaceProtocol}=="00"
ATTRS{supports_autosuspend}=="1"

looking at parent device '/devices/pci0000:00/0000:00:1d.0/usb2/2-1/2-1.2':
KERNELS=="2-1.2"
SUBSYSTEMS=="usb"
DRIVERS=="usb"
ATTRS{configuration}==""
ATTRS{bNumInterfaces}==" 1"
ATTRS{bConfigurationValue}=="1"
ATTRS{bmAttributes}=="80"
ATTRS{bMaxPower}=="100mA"
ATTRS{urbnum}=="1472"
ATTRS{idVendor}=="0813"
ATTRS{idProduct}=="1006"
ATTRS{bcdDevice}=="0092"
ATTRS{bDeviceClass}=="00"
ATTRS{bDeviceSubClass}=="00"
ATTRS{bDeviceProtocol}=="00"
ATTRS{bNumConfigurations}=="1"
ATTRS{bMaxPacketSize0}=="8"
ATTRS{speed}=="12"
ATTRS{busnum}=="2"
ATTRS{devnum}=="18"
ATTRS{devpath}=="1.2"
ATTRS{version}==" 2.00"
ATTRS{maxchild}=="0"
ATTRS{quirks}=="0x0"
ATTRS{avoid_reset_quirk}=="0"
ATTRS{authorized}=="1"
ATTRS{manufacturer}=="Fisher-Price"
ATTRS{product}=="DACS"
ATTRS{serial}=="DACS0000001"

looking at parent device '/devices/pci0000:00/0000:00:1d.0/usb2/2-1':
KERNELS=="2-1"
SUBSYSTEMS=="usb"
DRIVERS=="usb"
ATTRS{configuration}==""
ATTRS{bNumInterfaces}==" 1"
ATTRS{bConfigurationValue}=="1"
ATTRS{bmAttributes}=="e0"
ATTRS{bMaxPower}==" 0mA"
ATTRS{urbnum}=="475"
ATTRS{idVendor}=="8087"
ATTRS{idProduct}=="0020"
ATTRS{bcdDevice}=="0000"
ATTRS{bDeviceClass}=="09"
ATTRS{bDeviceSubClass}=="00"
ATTRS{bDeviceProtocol}=="01"
ATTRS{bNumConfigurations}=="1"
ATTRS{bMaxPacketSize0}=="64"
ATTRS{speed}=="480"
ATTRS{busnum}=="2"
ATTRS{devnum}=="2"
ATTRS{devpath}=="1"
ATTRS{version}==" 2.00"
ATTRS{maxchild}=="8"
ATTRS{quirks}=="0x0"
ATTRS{avoid_reset_quirk}=="0"
ATTRS{authorized}=="1"

looking at parent device '/devices/pci0000:00/0000:00:1d.0/usb2':
KERNELS=="usb2"
SUBSYSTEMS=="usb"
DRIVERS=="usb"
ATTRS{configuration}==""
ATTRS{bNumInterfaces}==" 1"
ATTRS{bConfigurationValue}=="1"
ATTRS{bmAttributes}=="e0"
ATTRS{bMaxPower}==" 0mA"
ATTRS{urbnum}=="31"
ATTRS{idVendor}=="1d6b"
ATTRS{idProduct}=="0002"
ATTRS{bcdDevice}=="0301"
ATTRS{bDeviceClass}=="09"
ATTRS{bDeviceSubClass}=="00"
ATTRS{bDeviceProtocol}=="00"
ATTRS{bNumConfigurations}=="1"
ATTRS{bMaxPacketSize0}=="64"
ATTRS{speed}=="480"
ATTRS{busnum}=="2"
ATTRS{devnum}=="1"
ATTRS{devpath}=="0"
ATTRS{version}==" 2.00"
ATTRS{maxchild}=="3"
ATTRS{quirks}=="0x0"
ATTRS{avoid_reset_quirk}=="0"
ATTRS{authorized}=="1"
ATTRS{manufacturer}=="Linux 3.1.0-1-686-pae ehci_hcd"
ATTRS{product}=="EHCI Host Controller"
ATTRS{serial}=="0000:00:1d.0"
ATTRS{authorized_default}=="1"

looking at parent device '/devices/pci0000:00/0000:00:1d.0':
KERNELS=="0000:00:1d.0"
SUBSYSTEMS=="pci"
DRIVERS=="ehci_hcd"
ATTRS{vendor}=="0x8086"
ATTRS{device}=="0x3b34"
ATTRS{subsystem_vendor}=="0x17aa"
ATTRS{subsystem_device}=="0x38b8"
ATTRS{class}=="0x0c0320"
ATTRS{irq}=="23"
ATTRS{local_cpus}=="ffffffff"
ATTRS{local_cpulist}=="0-31"
ATTRS{dma_mask_bits}=="32"
ATTRS{consistent_dma_mask_bits}=="32"
ATTRS{enable}=="1"
ATTRS{broken_parity_status}=="0"
ATTRS{msi_bus}==""
ATTRS{companion}==""
ATTRS{uframe_periodic_max}=="100"

looking at parent device '/devices/pci0000:00':
KERNELS=="pci0000:00"
SUBSYSTEMS==""
DRIVERS==""
(This post was last modified: 2011-12-25 02:04 by dodddummy.)
find quote
thevillain9 Offline
Junior Member
Posts: 5
Joined: Jan 2011
Reputation: 0
Location: NYC
Post: #167
has anyone got this working on xbmc eden (i'm running xbmcbuntu 11.10)? I'm not sure why its not working correctly. i disabled lirc in /etc/lirc/hardware.conf. It seems like most of the buttons work except for a few:

0300100000000000:KEY_F8
01000c0000000000:KEY_F9
0100100000000000:KEY_F10
0100080000000000:KEY_F11

It worked previously on my older version of xbmcbuntu (10.04 or 10.10)?
(This post was last modified: 2012-04-02 04:35 by thevillain9.)
find quote
linuxlainen Offline
Junior Member
Posts: 9
Joined: Nov 2011
Reputation: 0
Post: #168
Hi,

I am having a prblem with hid_mapper and my MCE remote. For some reason one press on the arrow keys gives 4 (or even more) on my xbmcbuntu box. Blacklisting the remote is working just fine, so no problems there. All other keys are also working. The only problem is repeatition of the arrow keys.

I have added the following line to rc.local file:
Code:
hid_mapper --lookup-id --manufacturer '0755' --product '2626' --map '/etc/mce_remote.map' &

The content of my mce_remote.map is as follows:

Code:
http://paste.ubuntu.com/919643/


Blacklisting in /usr/share/X11/xorg.conf.d/50-remote.conf is active and working
Code:
ection "InputClass"
Identifier "Remote blacklist"
MatchProduct "www.irfmedia.com"
Option "Ignore" "on"
EndSection

I have also tried with and without --disable repeat option, yet the same results are shown; two presses: 4 repeats 00000 4 repeats

Any idea how to solve this ?? Could it be a bug in the code?
Please advise.
find quote
UsagiYojimbo Offline
Member
Posts: 83
Joined: Feb 2010
Reputation: 1
Location: Debrecen, Hungary
Lightbulb  RE: Trying to use for Fisher Price Digital Studio Post: #169
(2011-12-25 01:22)dodddummy Wrote:  47 00 00 00 00 00 02 is when the pressure tip is not pressed and 47 00 00 00 00 00 00 is when it is pressed.

47 00 00 00 00 00 02 7c 02 a6 01
47 00 00 00 00 00 02 6d 02 a3 01
47 00 00 00 00 00 02 56 02 b0 01
47 00 00 00 00 00 02 49 02 b3 01
47 00 00 00 00 00 02 38 02 b8 01
47 00 00 00 00 00 02 29 02 c0 01
47 00 00 00 00 00 00 08 02 d0 01
47 00 00 00 00 00 00 de 01 e2 01
47 00 00 00 00 00 00 af 01 f0 01
47 00 00 00 00 00 00 87 01 f4 01
47 00 00 00 00 00 00 66 01 eb 01
47 00 00 00 00 00 00 54 01 d2 01
47 00 00 00 00 00 00 4e 01 ac 01
47 00 00 00 00 00 00 54 01 80 01
47 00 00 00 00 00 00 5b 01 55 01
47 00 00 00 00 00 00 6d 01 37 01
47 00 00 00 00 00 00 85 01 28 01
47 00 00 00 00 00 00 97 01 29 01

I think the last 4 bytes are co-ordinates, so you need something like the mouse mode.
(This post was last modified: 2012-04-16 17:48 by UsagiYojimbo.)
find quote
davy39 Offline
Junior Member
Posts: 37
Joined: Nov 2011
Reputation: 0
Post: #170
Hi,
Thank for this great soft that enable me to configure this cheap remote controler : http://www.aliexpress.com/product-gs/492...alers.html
I write a Howto (in french) here : http://doc.ubuntu-fr.org/tutoriel/hid to configure it whith lirc.

Are you thinking of create a graphical interface to easily configure remote controlers ?
find quote
Post Reply