Archive:Use any IR remote with OpenELEC: Difference between revisions
(credit goes to FishOil, http://forum.xbmc.org/showthread.php?pid=1656784) |
No edit summary |
||
Line 1: | Line 1: | ||
How | <section begin="intro" />How to get your infrared LIRC remote working in [[OpenELEC]]. This guide will show you how to modify OpenELEC so that it works with almost any [[LIRC]] remote. The four files are lircd.conf Lircmap.xml remote.xml and autostart.sh | ||
This is really simple and can be accomplished in 15-20 min.<section end="intro" /> | |||
This is really simple and can be accomplished in 15-20 min. | |||
You can likely use any remote.xml you can find. The one in the default root location (/usr/share/xbmc/system/keymaps) should be fine. Copy it and put it in the /storage/.xbmc/userdata/keymaps location as we might be tweaking it. | You can likely use any remote.xml you can find. The one in the default root location (/usr/share/xbmc/system/keymaps) should be fine. Copy it and put it in the /storage/.xbmc/userdata/keymaps location as we might be tweaking it. | ||
== Preparation == | |||
We must first change the protocol if you are going to use irrecord on the OpenELEC machine. | |||
[ | Execute this command before attempting the [http://forum.xbmc.org/showthread.php?tid=170372 Use Any IR Remote In The House] guide. | ||
<syntaxhighlight lang="bash">ir-keytable -p lirc</syntaxhighlight> | |||
== Guide == | |||
First thing is grab the IR remote of your choice and follow my previous tutorial [url=http://forum.xbmc.org/showthread.php?tid=170372]"Use Any IR Remote In The House"[/url] | First thing is grab the IR remote of your choice and follow my previous tutorial [url=http://forum.xbmc.org/showthread.php?tid=170372]"Use Any IR Remote In The House"[/url] | ||
skip the remote.xml part. | skip the remote.xml part. | ||
Start at step 13 and | Start at step 13 and don't use sudo. Also, use the terminal editor nano or do all of it on some other linux based machine. You will have to adjust a few things as OpenELEC is different. | ||
This will get you the first 2 files and consumes most of the 15 mins. | This will get you the first 2 files and consumes most of the 15 mins. | ||
Line 53: | Line 35: | ||
lircd --device=/dev/lirc0 /storage/.config/lircd.conf[/code] | lircd --device=/dev/lirc0 /storage/.config/lircd.conf[/code] | ||
You | You don't need the #!/bin/sh if you already have it in the file. | ||
Make the file executable | Make the file executable | ||
Line 66: | Line 48: | ||
and remote.xml in /storage/.xbmc/userdata/keymaps | and remote.xml in /storage/.xbmc/userdata/keymaps | ||
That's it! Piece of cake. Reboot | |||
If for any reason you want to go back to the way it was, simply | If for any reason you want to go back to the way it was, simply delete those files. | ||
Make sure the name of your remote matches in Lircmap.xml and lircd.conf | Make sure the name of your remote matches in Lircmap.xml and lircd.conf | ||
Here are the valid Lircmap.xml names. | Here are the valid Lircmap.xml names. Don't try to make up your own | ||
Don't go too crazy. Stick to the common names and it will mean less editing. | |||
Copy this entire thing to your Lircmap.xml (change your remote name) and only fill in the ones you need. | Copy this entire thing to your Lircmap.xml (change your remote name) and only fill in the ones you need. | ||
Revision as of 07:17, 23 March 2014
How to get your infrared LIRC remote working in OpenELEC. This guide will show you how to modify OpenELEC so that it works with almost any LIRC remote. The four files are lircd.conf Lircmap.xml remote.xml and autostart.sh
This is really simple and can be accomplished in 15-20 min.
You can likely use any remote.xml you can find. The one in the default root location (/usr/share/xbmc/system/keymaps) should be fine. Copy it and put it in the /storage/.xbmc/userdata/keymaps location as we might be tweaking it.
Preparation
We must first change the protocol if you are going to use irrecord on the OpenELEC machine.
Execute this command before attempting the Use Any IR Remote In The House guide.
ir-keytable -p lirc
Guide
First thing is grab the IR remote of your choice and follow my previous tutorial [url=http://forum.xbmc.org/showthread.php?tid=170372]"Use Any IR Remote In The House"[/url] skip the remote.xml part.
Start at step 13 and don't use sudo. Also, use the terminal editor nano or do all of it on some other linux based machine. You will have to adjust a few things as OpenELEC is different.
This will get you the first 2 files and consumes most of the 15 mins.
lircd.conf Lircmap.xml (see below for template)
Next create an autostart.sh file in /storage/.config (If you have one already just add the following to that file)
[code]#!/bin/sh
killall lircd ir-keytable -p lirc lircd --device=/dev/lirc0 /storage/.config/lircd.conf[/code]
You don't need the #!/bin/sh if you already have it in the file.
Make the file executable chmod +x /storage/.config/autostart.sh
Then
Place lircd.conf in /storage/.config/
Lircmap.xml in /storage/.xbmc/userdata
and remote.xml in /storage/.xbmc/userdata/keymaps
That's it! Piece of cake. Reboot
If for any reason you want to go back to the way it was, simply delete those files.
Make sure the name of your remote matches in Lircmap.xml and lircd.conf
Here are the valid Lircmap.xml names. Don't try to make up your own Don't go too crazy. Stick to the common names and it will mean less editing. Copy this entire thing to your Lircmap.xml (change your remote name) and only fill in the ones you need.
[code]<lircmap>
<remote device="MY-Remote-Name">
<left></left> <right></right> <up></up> <down></down> <select></select> <back></back>
<play></play> <pause></pause> <stop></stop>
<volumeplus></volumeplus> <volumeminus></volumeminus> <mute></mute>
<pageplus></pageplus> <pageminus></pageminus>
<power></power> <menu></menu> <info></info> <display></display> <title></title>
<red></red> <green></green> <yellow></yellow> <blue></blue>
<zero></zero> <one></one> <two></two> <three></three> <four></four> <five></five> <six></six> <seven></seven> <eight></eight> <nine></nine>
<skipplus></skipplus> <skipminus></skipminus> <reverse></reverse> <forward></forward>
<subtitle></subtitle> <language></language>
<channelplus></channelplus> <channelminus></channelminus>
<mytv></mytv> <mymusic></mymusic> <mypictures></mypictures> <myvideo></myvideo> <livetv></livetv> <recordedtv></recordedtv> <liveradio></liveradio> <epgsearch></epgsearch>
<guide></guide>
<record></record> <start></start> <star></star> <hash></hash> <clear></clear> <enter></enter> <xbox></xbox>
<playlist></playlist> <teletext></teletext>
</remote>
</lircmap>
[/code]
You also may want to have a look at [url=http://forum.xbmc.org/showthread.php?tid=189617]Understanding LIRC & XBMC[/url]
[hr]
If it doesn't work the first step is to find out if LIRC is configured correctly
SSH into the box and type irw
Push some buttons on the remote.
Your custom remote name should be displayed along with the button name.