How To: Map RC6 Remote "Start" button to "Kodi ActivateWindow(home)"

SYSTEM: RC6 Media Center Remote, 1G RPI2, latest OSMCas of July 12, 2015
GOAL: I’d like the “Green Button” (circled in red) to go HOME in Kodi
DETAILS: I’d like the “Green Button” (circled in red) to go HOME in Kodi (I think I need it to call “ActivateWindow(home)”). Right now the button does nothing. Even though there is a specific lircd file for this remote - rc6-mce-lircd - I am not using it (found it sends double commands with each key press). Instead I am using xbox360-lircd, which seems to work fine (no doubles)… except for the Green Button. :smile:

TRIED: I traced the key using tail \ kodi.log and found this below. Looks like I need to map KEY_MEDIA.

12:07:52 T:1956737024   DEBUG: LIRC: Update - NEW at 674406:e2 0 KEY_MEDIA linux-input-layer (KEY_MEDIA)
12:07:52 T:1956737024   DEBUG: LIRC: Update - NEW at 674767:e2 0 KEY_MEDIA_UP linux-input-layer (KEY_MEDIA_UP)
12:07:57 T:1956737024   DEBUG: LIRC: Update - NEW at 679089:e2 0 KEY_MEDIA linux-input-layer (KEY_MEDIA)
12:07:57 T:1956737024   DEBUG: LIRC: Update - NEW at 679329:e2 0 KEY_MEDIA_UP linux-input-layer (KEY_MEDIA_UP)

I tried adding the following to /home/osmc/.kodi/userdata/keymaps/REMOTE.XML but it didn’t work:

<keymap>
	<global>
		<remote>
			<KEY_MEDIA>ActivateWindow(home)</KEY_MEDIA>
		</remote>
	</global>
</keymap>

I’m really not sure what to do from here. I think I’m close but I am just missing the code I think for REMOTE.XML (translation from KEY_MEDIA to ???).

Please help.
–UN

PS: Linux noob here, so pls keep that in mind. :slight_smile:

Well. :blush: Found this and fixed it. :smile: Amazingly it had EVERYTHING I needed, including how to get R\W access over SSH\WinSCP (another issues I was having). Here’s what I did:

-Changed to osmc-remote-lircd using the “OSMC Settings” Remote section.
-Found Lircmap.xml in usr/share/kodi/system. Used WinSCP to copy to my PC.

  • Added KEY_MEDIA to the section.
  • Copied Lircmap.xml to /home/osmc/.kodi/userdata using WinSCP
  • Rebooted Pi.

Profit!

Re: “Added KEY_MEDIA to the section.”

What section? “linux-input-layer”?