Help with keymap
#1
I have just got an Gyro Remote which works as a usb hid keyboard. The cursor keys work and so do the number keys but the other keys (play, stop, etc ) do nothing.

If I use xev I can see the events being triggered as I press the keys. My question is how do I use that information to setup the keys in keymap.xml?

I know that it is possible to set <key id=something> but it does not seem to relate directly to the xev info. I have looked in ButtonTranslator.cpp and SDLKeyboard.cpp but cannot figure this out.

Any help greatly appreciated.
Reply
#2
Enable printing of button codes in advancedsettings.xml. see manual.
Reply
#3
I tried that but it did not show anything. Does this work for keyboards as well as lirc remotes?
Reply
#4
For my UltraX remote (which is a HID device) I use xmodmap to map key events to key events recognized by XBMC.
Reply
#5
nomorenight,

That is an option but I also plan to use it with other linux apps so this may become complex to ensure that they are all changed.

If I could just map those keys into keymap.xml then I would be happier but failing that xmodmap is the way to go.

Could you post your xmodmap? I would have to change the IDs but it would save a bit of time. Where do you place a custom xmodmap under ubuntu?

Thanks
Reply
#6
stuartmarsden Wrote:I tried that but it did not show anything. Does this work for keyboards as well as lirc remotes?

No I don't suspect it does. Try using
# irw
for LIRC buttons.
(I'm not on linux now so I can't be 100% that's the command but it should be in the lirc forumthread if you scourge through it)
If you have problems please read this before posting

Always read the XBMC online-manual, FAQ and search the forum before posting.
Do not e-mail XBMC-Team members directly asking for support. Read/follow the forum rules.
For troubleshooting and bug reporting please make sure you read this first.

Image

"Well Im gonna download the code and look at it a bit but I'm certainly not a really good C/C++ programer but I'd help as much as I can, I mostly write in C#."
Reply
#7
My remote does not use lirc but acts as a keyboard.
Reply
#8
stuartmarsden Wrote:Could you post your xmodmap? I would have to change the IDs but it would save a bit of time. Where do you place a custom xmodmap under ubuntu?

Sure, here: http://bleedingtree.mine.nu/xmodmap.txt

My mappings are based on an UltraX map for MythTV (http://www.mythtv.org/wiki/index.php/Log...dia_Remote), so it's not a pretty sight (and I have only mapped the XBMC commands I needed). Lines starting with "!" is ignored.

Put your mappings in .Xmodmap (in your home dir).
Reply

Logout Mark Read Team Forum Stats Members Help
Help with keymap0