What changed in LIRC


I’ve just upgraded my computer with openSuse 12. 1. Before I was using 11.3 and my remote was working fine with LIRC.

I was hoping that by just copying the lirc.conf from my previous install would be enough to get LIRC working. But this is not the case:

The logs seems to show that lircd gets the right driver (mceusb)

Jan 3 02:18:46 thor lirc[9920]: Starting lircd (/dev/input/ir)…done
Jan 3 02:18:46 thor kernel: 3493.854538] input: MCE IR Keyboard/Mouse (mceusb) (lircd bypass) as /devices/virtual/input/input28

I had to link /dev/lirc to /dev/lirc0 in order to use mode2. The program detects the IR signals

When I try to use irw, I detect nothing.

Any idea on what has changed since 11.3 and would cause this failure?


Various lirc modules have been moved into the kernel over recent months, including mceusb. resulting in changes to the needed lircd.conf. The appropriate lircd.conf to use moved to the devinput device for the kernel modules, /usr/share/lirc/remotes/devinput/lircd.conf.devinput there is some basic information on the lirc section in the mythtv wiki.

I had the remote working after a heap of problems finding out about these changes with 11.4, and recently after a hardware failure and rebuild I went to 12.1 and am having issues with it again. My current issue is in the hardware section titled http://forums.opensuse.org/english/get-technical-help-here/hardware/470552-mythtv-lirc-kernel-mceusb-12-1-a.html.

I am a bit of a loss to offer any further advice as I am unsure just where the problems lie i.e. with udev, Xorg, or elsewhere. There was alengthy discussion on these forum a while ago on lirc not working in 11.4, that maybe worth searching for.

Best wishes for 2012

I had the exact same problem, remote was working just fine in 11.3, but broke when I upgraded to 12.1. It did this on both my main HTPC and a Acer Revo 3700 in my bedroom. Both had the same remote ir receiver.

On the main HTPC, my remote did work right away, but some buttons would show up as multiple presses, making xbmc and mythtv unusable. I tracked this down to (as you pointed out) the new kernel treating the remote as a keyboard, though only for some keys (mostly the arrows and OK buttons). To get rid of this, I created the following file named rclocal in /etc/init.d (as root)

revo-htpc:/etc # cat /etc/init.d/rclocal 
# /etc/init.d/rclocal
# Provides: rclocal
# Required-Start: $network $remote_fs
# Required-Stop: $network $remote_fs
# Default-Start: 5
# Default-Stop: 0 1 2 3 6

echo lirc > /sys/class/rc/rc0/protocols 2>/dev/null || true

and then had to enable it to start via chkconfig

chmod 755 /etc/init.d/rclocal
chkconfig rclocal on

From my understanding, this disables the kernel driver from working and instead will use the old lirc driver (I could be wrong in my understanding here, but it did fix my problem).

Now, to fix the remote on the Revo which sounds more like the problem you are having, I had to do the above, but also change the following in /etc/sysconfig/lirc




and restart lirc

sudo /etc/init.d/lirc restart

What this seemed to do is to change lirc from trying to use the wrong device to read from. Here is what I got when it wasn’t working

revo-htpc:/etc # ps aux | grep lirc
root      8094  0.0  0.0  20144   564 ?        Ss   16:00   0:00 /usr/sbin/lircd -H dev/input -d /dev/input/ir

Here is what I get when it is working

revo-htpc:/etc # ps aux  | grep lirc
root      8130  0.0  0.0  20144   564 ?        Ss   16:01   0:00 /usr/sbin/lircd -d /dev/lirc0

So, changing the /etc/sysconfig/lirc file changes it to load /dev/lirc0 as the remote device instead of /dev/input/ir.

Hope that helps you guys, it worked for me.

Now just have to fix my issue with no sound coming through HDMI on the Revo after the update. :expressionless:

I note you went from 11.3 to 12.1, in my case I had been on 11.4 and had changed from using the lirc mceusb module to the kernel module & devinput.

With 11.4 that was working OK, it only fell apart when I had to do a fresh install of 12.1 and redo the remote setup, keeping the .lircrc file as before.
Did you use the lirc.conf.mceusb file for the lircd.conf, or the lirc.conf.devinput file?

There is quite a difference between both those files, and when I went to using devinput it was a fairly big task getting the .lircrc file right for mythtv.

I believe that there may be a solution to the problem, using udev rules and/or xorg conf , that will allow the use of the in-kernel driver. In the process of searching around the udev “remote as keyboard” problem there was a reference to a solution using a udev rule that in part referred to using an ‘echo’ statement not unlike yours above. I may have another look for that, and re-read the information to see if there is a connection.

However, I will also look at your suggestion and see if that does resolve the problem for me.

Kind regards,

If I understand you correctly, no, I never used the remote as a keyboard. I believe I always was using the mceusb lircd.conf file. I should point out that I did the update by doing a zypper dup from 11.3 to 11.4, then again to 12.1, so most of my config files should not have changed.

Doing a quick check that aside from one or two lines (probably due to the update in lirc) my lircd.conf file is indeed based on lircd.conf.mceusb.

My understanding of the state of the included kernel driver is that support is poor for buttons other than the standard arrows and OK buttons. I use some of the other buttons for various things and didn’t want to lose these, so I was trying to stick with the old, familiar lirc that I had been using.

If you want any of my files such as lird.conf, .lircrc, etc…, just let me know and I can post them up somewhere if you think it may help. But, if you are trying to use the keyboard route, they may not be of any help, sorry.

Slight misunderstanding there. I have been, and want to continue using the remote strictly a a remote with all the functionality I can get. (Apart from the standard mce remote, I also have a logitech Harmony 525 which is setup as the mce remote, but also controls my other equipments as well) If I get the mce remote working again, then the harmony will also.

Originally I had upgraded similarly to yourself using zypper, 11.3, - 11.4 - 12.1 I had a lirc problem with the remote in 11.4, which was successfully resolved changing to using the in-kernel module & lircd.conf based on the lircd.conf.devinput module. That went OK with 11.4, but after the upgrade to 12.1 there were a number of intermittent motherboard/power & powere supply problems. This resulted in a rebuild with new case, power supply, motherboards (&cpu) and although all disks were OK, I had a number of problems trying to use the remote & various other software related problems. Therefore, I did a complete format of the main partition and a new install of 12.1.

The changes in the newer kernels (2.6.x? > current 3.x.x.) have introduced more modules for remotes eg. imon, mceusb & some others. Once the remote module is part of the kernel that remote ought to be “fully functional” out of the box. You still have to have a valid lircrc file for mythtv etc. and the ir signal needs to get through.
So the state of the current kernel is that if the driver is there for your remote then “all buttons” not just arrow keys & OK should be working.

Just to clarify this , if I test my remote using ir-keytable -t I see a full response for all keys pressed, with the scancodes and also the ‘KEY_NAME’ as in my lircd.conf which is based on the lircd.conf.devinput file.

If I try to use irw then I see responses only for the left,right,up & down arrow keys and the responses are like D^ A^ .

A check of the Xorg.0.log shows the IR Transceiver for the remote an FIC eHome MCE which is using evdev and “configuring as keyboard”

My issue seems to be get the ir signal through lircd to mythtv , maybe this really isquestion for one of the tech gurus at opensuse with a good knowledge of Lirc, or even a question for the person who builds the lirc or kernel packages.

Thanks for the offer of those files, however I believe that I would have similar or possibly the same files on hand in my archives. It is just that at present, I would like to see this “in-kernel” module working the way others seem to have succeeded all be it on different distro’s.

Thanks for your assistance.

Kind regards,

I think I understand you now. I am also using a Harmony remote (650) as my mceusb remote for the main htpc, and a Harmony 670 in my bedroom.

I was mostly looking for a way to get it working, and what I did seems to work for me, for now. I think I had close to the same issue, in that my main htpc would see the same responses for the arrow keys in irw, but I would also get the response that I was expecting from my old install before the update.

If my memory is correct, I believe the irw output was something like

0000000000001794 00 Up D^D^D^D^D^ mceusb
0000000000001794 01 Up D^D^D^D^D^ mceusb

and corresponding output for the other arrows. But, I was getting output like this for buttons like “play”

0000000000001795 00 Play mceusb
0000000000001795 01 Play mceusb

Note, the extra control characters for the arrows. That was making mythtv and xbmc to interpret too many keypresses when I tried to navigate using the remote. I was mostly just looking for a way to stop it from trying to use the keyboard characters at all. As I understand you, you are not getting any output from irw in the case of buttons other than the arrows, and the arrow keys are getting you the “D^” stuff, which is what was happening for me on the Acer Revo. In that case I was expecting to have the same issue I did on my main htpc, so I had already used the same steps to get the keyboard functionality to stop before I realized that I also needed to add the “device” line to lircd.conf as outlined in my previous post.

But, you are trying to make it use the kernel keyboard driver instead of lirc, and my solution will not do that. I wish I could be of more help, but until it breaks again, I am ok with the way mine is.

It sounds to me like we both had the same initial problem, that the remote arrow keys were the only thing that worked, at least in irw. But you are trying to make the rest of the keys work with the kernel driver, while I went with disabling the kernel driver and only using the lirc driver.

I’m still not sure that is exactly what I am doing, because when I restart lirc, I get an error that lirc_mceusb can not be loaded, so I am not sure what driver is being used, but it works. And I am going to leave well enough alone for now. :wink:

Good luck with yours.

Thanks very much for that reply.

You have output similar to what I am getting with irw although I do not get scancodes or mceusb, only the A^ (actually A,B,C,D depending on which arrow).

I have also discovered that the rclocal script in post 3 above did not work for me because my device had changed from rc0 to rc3. Further reading on the mythtv list clarified that the rc0 is not persistent if the device is disconnected or reconnected. I had been using it another machine for testing. After a cold boot it has returned to rc0.

I am also looking at udev rules discussions, I feel sure I had seen a similar echo > script to yours in post 3 in a udev rule relating to infra-red transceivers, but not sure of the context there.

The comments you have made have very helpful and have clarified some issues, I will keep on this track and hopefully end up with a working solution.

Thank you,

I found that “echo” line here: Configuring mceusb for frontend with 3.0 kernel | MythTV | Users (3rd post).

However, I didn’t have an /etc/lirc/hardware.conf file, so I put it in the rclocal file, which I can’t remember where I saw that. Looking back on it, I could have put it in the /etc/sysconfig/lirc file probably, but it is working for me now, so I will leave it as is.

Just out of curiosity, what is your output for a “ps aux | grep lirc”? Does it point to /dev/lirc0 or /dev/input/ir? I had to change the device in /etc/syconfig/lirc to /dev/lirc0 for me to get the scancodes in irw to show up. However, I’m not sure that is what you want with trying to get the kernel driver to work…

If you do manage to get the udev rules working, can you post that up so that if I (or anyone else) wants to do it that way, can get it working?

Well it seems I have now got this working, using the in-kernel modules. Thanks for your last reply, and in response to your question here is the output I now have on my working system.

mythtv@lounge:~> ps aux | grep lirc
root      1668  0.0  0.0  20144   808 ?        Ss   15:34   0:00 /usr/sbin/lircd -H devinput -d /dev/input/by-id/usb-FIC_eHome_Infrared_Transceiver_FI001Swn-event-if00
mythtv    3460  0.0  0.0   8048   872 pts/5    S+   15:42   0:00 grep --color=auto lirc

As you see I have /dev.input/by-id !

However I have two other PC’s both with mythtv installed, a slave backend on which I have not really setup a remote, although lirc has been installed. On that machine I have /dev/input/ir !

The third machine which which has a Silverstone case with the Soundgraph Imon remote, and which also had remote issues now has /dev/input/by-id !

Just in regard to “input by-id” this uses the device name rather than the event number. The device name is constant, whereas the event number can change.

Now to clarify, software versions are common across my machines, although I do have one which is my main machine for general daily use as well as being a slave backend.

mythtv@lounge:~> uname -a
Linux lounge 3.1.0-1.2-desktop #1 SMP PREEMPT Thu Nov 3 14:45:45 UTC 2011 (187dde0) x86_64 x86_64 x86_64 GNU/Linux

mythtv@lounge:~> rpm -q lirc

All packages are downloaded from the opensuse repositories.

MythTV is from Packman is

Version: 0.24.1-6.2

When I was on 11.4 I was able to get the MCE remote working & the Logitech Harmony 525 remote working by modifying the Xorg.conf file.
Basically [FONT=Verdana][size=2]by adding this to xorg.conf (to be correct it perhaps ahould have been under xorg.con.d

Section “InputClass”
Identifier “Ignore Philips mce remote” # changed to “Hauppage mce remote”
MatchProduct “Media Center Ed. eHome Infrared Remote Transceiver (0471:0815)” #changed
the reference in brackets as per my log file.
MatchIsKeyboard “true”
Option “Ignore” “true”
This worked for 11.4, but after 12.1 it failed.

You mentioned you had found that “echo” line here: Configuring mceusb for frontend with 3.0 kernel | MythTV | Users (3rd post).

In fact this is the reference I was trying to remember, a post by Jarod Wilson:
Lirc & Harmony 525 Key repeat problem | MythTV | Users (post 12.)

[FONT=Verdana][size=2]Yeah, um, still Doing It Wrong™. This has been covered a TON
of times on this list and the lirc list. The new in-kernel drivers
can use either or both lirc userspace decode and in-kernel decode,
with key events delivered via the standard linux input layer.

echo lirc > /sys/class/rc/rc0/protocols

is the more correct fix. File an RFE asking that your distro’s
lirc initscript does that for you, so you don’t get both lirc and
native linux input layer keypresses at the same time.

In this thread at post 8 I had mentioned my eHome transceiver had changed from rc) to rc3 seemingly because I had removed it to try on another PC. I subsequently replaced the transceiver on “lounge” the pc for my main frontend, after I turned the pc off, rebooted and the transceiver was back on rc0.

I then followed Jarods instructions for the echo command. . . . and it worked

irw is functional:

mythtv@lounge:~> irw
000000008001006c 00 'KEY_DOWN' devinput
0000000080010067 00 'KEY_UP' devinput
000000008001006a 00 'KEY_RIGHT' devinput
000000008001006c 00 'KEY_DOWN' devinput
0000000080010160 00 'KEY_OK' devinput
00000000800100cf 00 'KEY_PLAY' devinput
00000000800100a7 00 'KEY_RECORD' devinput
0000000080010080 00 'KEY_STOP' devinput
00000000800100d0 00 'KEY_FASTFORWARD' devinput
00000000800100a8 00 'KEY_REWIND' devinput
0000000080010201 00 'KEY_NUMERIC_1' devinput
0000000080010202 00 'KEY_NUMERIC_2' devinput
0000000080010203 00 'KEY_NUMERIC_3' devinput

I followed the same steps on the Silverstone pc with the Imon, and that is also working

Just to clarify, I am using the in-kernel modules mceusb on lounge, and the imon on the Silverstone.


## Type:        string
## Default:     ""
# read from given device

## Type:        string(lirc_bt829,lirc_gpio,lirc_i2c,lirc_it87,lirc_parallel,lirc_sir,ir-kbd-i2c,ir-kbd-gpio)
## Default:     ""
# load given lirc driver module

## Type:        string
## Default:     ""
# listen for network connections on specified port.
# WARNING: don't use this on a machine with an internet
# connection as lircd is running as root!

## Type:        string
## Default:     ""
# connect lircd to specified host
lounge:/ # 

I also copied file /usr/lirc/remotes/devinput lircd.conf.devinput to /etc/lirc/lircd.conf

All now seems to be resolved although it would be nice if these little things could be automated withing the various installation scripts that the opensuse developers do so well.

If anyone needs more information on my setup feel free to ask, I could post the lircrc file I have used if needed.

Kind regards,