SwedishGojira Wrote:I found this and this.
Yep, these are the correct pages.
Quote:I have a button on my Imon-pad that IRW id as "AspectRatio".
On this button I want the XBMC function of the same name, "AspectRatio".
First get the real LIRC button name. Start a terminal and enter "irw" - then press your AspectRatio button and see what name LIRC reports. Let's assume that the LIRC button name is
Ratio. I chose another name here to make it easier to follow the rest of my post. Maybe the name of your button is AspectRatio, too - you have to check that.
Quote:I've tried adding this to my Keymap.xml :
Code:
<universalremote>
<aspect>AspectRatio</aspect>
</universalremote>
No, that's not the way it works. You can either treat your remote as a XBMC remote *OR* treat it as a universal remote. In the standard configuration your remote is treated as a XBMC remote and therefore you have to edit the <remote> section and not the <universalremote> section.
But you have to start with adjusting your Lircmap.xml and then you edit the Keymap.xml.
Quote:and this to my Lircmap.xml :
Code:
<aspect>AspectRatio</aspect>
But it didn't work so I guess I've understood it wrong...
Well, you understood the concept, but not the way XBMC works. XBMC defines some "button strings" which can be mapped to your remote's buttons. You can find all valid button strings on the Keymap.xml page in the wiki (
http://wiki.xbmc.org/?title=Keymap.xml - Section: Remote Buttons). There is a table and the first column named "button string" defines all strings which are valid. YOU CAN NOT DEFINE YOUR OWN BUTTON STRINGS! This is important and a common mistake [you did it :-)].
Now that you know which button strings are valid, you can map them to the names of your remote's buttons in
Lircmap.xml. The format of an entry is:
Code:
<button string> LIRC button name </button string>
So if you want to map the button
Ratio you have to first find a button string which you do not already use. Check the <remote device="YOU_REMOTE_NAME"> section in Lircmap.xml which belongs to your remote and compare it to the button string table in the wiki. You need a button string which is not mapped to a remote button, yet. Let's suppose you do not use the button string
star, yet. Map the button string "star" to the button name "Ratio" in Lircmap.xml:
Now you have to edit your Keymap.xml file and map the button string "star" to the XBMC action "AspectRatio". You have to do this in one of the <remote> sections of Keymap.xml, as you use predefined button strings.
Code:
<keymap>
<global>
<remote>
<star>AspectRatio</star>
<....>....</....>
</remote>
<.....>
<...>....</...>
</....>
</global>
</keymap>
That's it if you only want to map a few more buttons. But what happens if your remote has many more buttons than "button strings" are available? Then you have to follow this guide:
http://forum.xbmc.org/showthread.php?tid=45972
This will convert your remote configuration into a universal-remote configuration which lets you map up to 256 buttons.
Temar