[mythtv-users] USB IR Receivers

Kirk Bocek t004 at kbocek.com
Tue Sep 1 23:04:46 UTC 2015



On 9/1/2015 7:40 AM, Kirk Bocek wrote:
>
>
> On 8/31/2015 9:49 PM, Alec Leamas wrote:
>> On 01/09/15 06:05, Kirk Bocek wrote:
>>
>>> So following [4] I can unbind the usb-hid driver. If I load mceusb, I
>>> now have  /sys/bus/usb/drivers/mceusb as a place to bind the device to.
>>> But I'm having trouble figuring that out. It seems like the device
>>> string changes after unbinding. I can see the receiver under ls
>>> /sys/bus/usb/devices/ but can't figure out what string to use to refer
>>> to it.
>>>
>>> udevadm info -a /sys/bus/usb/devices/whatever shows a whole bunch of
>>> devices and not just the receiver.
>>
>> Basically, if you are able to load the mceusb device correctly the 
>> kernel will create a /sys/class/rc entry. What does dmesg say after 
>> unbinding usb-hid and reloading mceusb?
>>
>
> Reboot...
>
> $tree /sys/bus/usb/drivers/usbhid
> /sys/bus/usb/drivers/usbhid
> âââ 1-2:1.0 -> 
> ../../../../devices/pci0000:00/0000:00:14.0/usb1/1-2/1-2:1.0
> âââ bind
> âââ module -> ../../../../module/usbhid
> âââ new_id
> âââ remove_id
> âââ uevent
> âââ unbind
>
> $ echo -n "1-2:1.0" > /sys/bus/usb/drivers/usbhid/unbind
>
> ]$modprobe -v mceusb
> insmod 
> /lib/modules/4.1.5-100.fc21.x86_64/kernel/drivers/media/rc/rc-core.ko.xz
> insmod 
> /lib/modules/4.1.5-100.fc21.x86_64/kernel/drivers/media/rc/mceusb.ko.xz
>
> $dmesg
> ...
> [  860.653616] usbcore: registered new interface driver mceusb
>
> $tree /sys/bus/usb/drivers/mceusb/
> /sys/bus/usb/drivers/mceusb/
> âââ bind
> âââ module -> ../../../../module/mceusb
> âââ new_id
> âââ remove_id
> âââ uevent
> âââ unbind
>
> $ echo -n "1-2:1.0" > /sys/bus/usb/drivers/mceusb/bind
> -bash: echo: write error: No such device
>
> $udevadm info -a /sys/bus/usb/devices/1-2:1.0

Still playing with this, I tried manually loading a few more kernel 
modules that aren't being pulled in:

$modprobe -v lirc_dev
$modprobe -v ir_lirc_codec
$modprobe -v ir_rc6_decoder

$dmesg
...
[30886.627601] lirc_dev: IR Remote Control driver registered, major 248
[31055.633750] IR LIRC bridge handler initialized
[31141.142931] IR RC6 protocol handler initialized

$lsmod |grep lirc
ir_lirc_codec          16384  0
lirc_dev               20480  1 ir_lirc_codec
rc_core                28672  4 lirc_dev,ir_lirc_codec,mceusb,ir_rc6_decoder

But I still can't bind the USB device:

$echo -n "1-2:1.0" > /sys/bus/usb/drivers/mceusb/bind
-bash: echo: write error: No such device

Alec, as you mentioned in another post, loading mceusb did create 
/sys/class/rc. However it is empty.



More information about the mythtv-users mailing list