Camelot Beta 1 MCE remote support
#16
Keep in mind that if you apply the registry change you will no longer be able to start your MCE with the green button.
Reply
#17
I'm trying to get my MCE keystroke sending remote working on my XBMC live box. (need vdpau, so booting into win7 is not an option =\).

I downloaded the camelot beta2 source applied the JR-091214.patch, compiled and installed, but without success with regards to the remote. I added the keyboard.xml (found on ratsauce.plus.com) to the keymaps folder.

Is JR-091214.patch all thats needed to get things up and running, or do I need to apply one of the older patches as well? Or is this a windows only patch?
Reply
#18
@Mr V: the patch should be all you need. I haven't attempted a Linux build but as you've no doubt seen the patch is very simple. Have you got a debugger in your Linux development environment? If so it should be easy to see why the keystrokes aren't working.
Reply
#19
Solved it, now everything is working perfectly.

The problem was that WinEventsWin32.cpp isn't included/used on Linux. Instead the file WinEventsSDL.cpp is used.

The unicode value is f*cked up when pressing ctrl
LEFT_CTRL+P gives me (unicode=16)
KBDN scancode=33 sym=112 mod=64 unicode=16 state=1 type=2 which=0

Original Code in WinEventsSDL.cpp
Code:
case SDL_KEYDOWN:
    {
      // process any platform specific shortcuts before handing off to XBMC
#ifdef __APPLE__
      if (ProcessOSXShortcuts(event))
      {
        ret = true;
        break;
      }
#endif

      XBMC_Event newEvent;
      newEvent.type = XBMC_KEYDOWN;
      newEvent.key.keysym.scancode = event.key.keysym.scancode;
      newEvent.key.keysym.sym = (XBMCKey) event.key.keysym.sym;
      newEvent.key.keysym.mod =(XBMCMod) event.key.keysym.mod;
      newEvent.key.keysym.unicode = event.key.keysym.unicode;
      newEvent.key.state = event.key.state;
      newEvent.key.type = event.key.type;
      newEvent.key.which = event.key.which;

changed to:

Code:
case SDL_KEYDOWN:
    {
      // process any platform specific shortcuts before handing off to XBMC
#ifdef __APPLE__
      if (ProcessOSXShortcuts(event))
      {
        ret = true;
        break;
      }
#endif

      XBMC_Event newEvent;
      newEvent.type = XBMC_KEYDOWN;
      newEvent.key.keysym.scancode = event.key.keysym.scancode;
      newEvent.key.keysym.sym = (XBMCKey) event.key.keysym.sym;
      newEvent.key.keysym.mod =(XBMCMod) event.key.keysym.mod;
      newEvent.key.keysym.unicode = event.key.keysym.unicode;
      newEvent.key.state = event.key.state;
      newEvent.key.type = event.key.type;
      newEvent.key.which = event.key.which;

if(event.key.keysym.mod >= 64)
{
newEvent.key.keysym.unicode = event.key.keysym.sym;
}

A bit ugly, but it works. Shifts only gives modifiers 1+2 and correct unicode, picked 64 since it was the lowest value found on a ctrl/alt key on my kb...
Reply
#20
@Mr V: this is poor design on my part. I should have anticipated there would be a problem on Linux. I've updated my patch so it should work on both Windows and Linux. Would you be able to try it? The patch is at http://www.ratsauce.plus.com/JR-091217.patch. It is still derived from the 25615 build like the last patch.

If you could test it that would be very useful. I don't have a Linux system set up at the moment so I can't check my changes will work on Linux as well as Windows.

Any Mac users out there want to try the patch?

JR
Reply

Logout Mark Read Team Forum Stats Members Help
Camelot Beta 1 MCE remote support0