Comment 10 for bug 454371

Revision history for this message
jim_charlton (charltn) wrote :

The comments above are rather cryptic to the novice (like me). It was a bit of a struggle to know exactly what to do to get this working. So here is a more detailed account of what I had to do to get my IR remote to work. Note... I am using a Hauppage PVR-1600 card and the grey topped remote.

Install the sources for lirc-0.8.6 in /usr/src/lirc-0.8.6. Install the kernel header files (sudo apt-get install linux-headers-$(uname -r)). I also installed the linux source files but I don't think it was necessary. I did not recompile the kernel at any time.

 Cd to the /usr/src/lirc-0.8.6 directory and run ./configure. For device, choose "other" and then "Linux Input Layer". Recompile everything with 'make'. Install with 'make install'.

 Install /etc/lirc/lircd.conf from http://lirc.sourceforge.net/remotes/devinput/lircd.conf.devinput. It is generic for the remote and using linux input layer. Remove any /etc/lircd.conf file. It should not be there.

Make sure that you have only one copy of lircd on your system ('updatedb' and 'locate lircd'). I found that there were copies in /usr/local/sbin and /usr/sbin with the newer one that was just compiled in /usr/local/sbin. Copy it over the one in /usr/sbin.

Edit /home/<yourusername>/.lircrc to put the new codes in lircd.conf into .lircrc.

If you reboot at this point, the ir_kbd_i2c driver will be loaded and connect the ir chip on the Hauppauge card to an event# in /dev/input/event#. You can figure out which event# by looking at /proc/bus/input/devices and looking for the device with NAME=i2c IR ...... You can hard code that device number into /etc/lirc/hardware.conf. But the number may change as you change other things so this is not a perfect solution.

Better is to do the following

Put file called 30-ir_event.rules with the line
***
KERNEL=="event[0-9]*", ATTRS{name}=="i2c IR *", SYMLINK+="input/hauppage"
***
(all on one line) into /etc/udev/rules.d. The ATTRS{name} variable can
be obtained by looking into /proc/bus/input/devices (in case you are using a different card). This udev rule will create a device entry (symlink) in /dev/input called hauppage that will always point to the proper event# in the same directory.

Now point your lircd at /dev/input/hauppage by putting it
into /etc/lirc/hardware.conf. Edit the lines given below.
.
.
.
REMOTE_DEVICE="/dev/input/hauppage"
REMOTE_LIRCD_CONF="/etc/lirc/lircd.conf"
REMOTE_LIRCD_ARGS="--device=/dev/input/hauppage --driver=dev/input"
.
.
.

At this point if you reboot you will find that 'lsmod' shows that the iir_kbd_i2c module is loaded and 'ps -ef | grep lircd' gives "root 953 1 0 18:04 ? 00:00:00 /usr/sbin/lircd --output=/var/run/lirc/lircd --device=/dev/input/hauppage" (on my machine) (all commands run as root).

This is (as best I can remember) what I did to get my remote to control mplayer (I put mplayer controls in .lircrc) and watch TV with 'mplayer /dev/video0'. I use a propriety program (you can get a copy by writing to me) to change channels but channels can also be changed with 'ivtv-tune -c #'

I hope that this may be of help to others.