Button change in Eden
#1
Question 
Hey Guys,

The behavior of one of the buttons on my remote changed in Eden. It didn't do anything in xbmc before but did launch my default browser (kinda handy!), now however it jumps to the first menu item!? Unfortunately that button doesn't pass a keyboard combination so if someone could point me to the file that has the default key bindings in it I can hopefully figure out what the media center command is for that button.

Thanks!
Reply
#2
Grab Showkey from http://xbmcmce.sourceforge.net/ and use it to see what the button is sending. My guess is that it's sending an APPCOMMAND message. In Eden you can create APPCOMMAND mapping files just like key mapping files.

JR
Reply
#3
You're right it is sending an APPCOMMAND (WM_APPCOMMAND 7 to be exact) but I wasn't aware that you could map those in xbmc... would you mind pointing me to the syntax I should be using for those?
Reply
#4
Look in C:\Program Files\XBMC\system\keymaps and you'll find an appcommand.xml file. This contains all the default mappings. Don't modify this file or you'll lose the changes when you install the release Eden. Create a new appcommand.xml in your userdata folder and add the appcommand mappings you want to this file. You need only add the mappings you want to change as XBMC reads the default mappings then your user mappings, and the user mappings add to/override the system mappings.

To open the userdata appcommand.xml press Windows-R and in the run dialog type:

notepad "%appdata%\xbmc\userdata\keymaps\appcommand.xml"

click OK and answer Yes when you're asked to create a new file.

JR
Reply
#5
Awesome thanks, that makes remapping some keys WAY easier!

Okay last question, is there a way in the xml to remove/ignore that command from the appcommand.xml? Basically I would like the button to respond the same way it does when xbmc isn't running.
Reply
#6
loki131 Wrote:Okay last question, is there a way in the xml to remove/ignore that command from the appcommand.xml?

You have two options:

1. ignore the appcommand and let Windows deal with it. For example the volume appcommands are treated this way so they control the Windows volume. To do this put the entry in as e.g. <volume_down/>. However note that you need to do this in the system appcommand.xml (even though I normally recommend not editing that!).

2. swallow the appcommand and do nothing. This means Windows won't receive the appcommand. To do this set the action to "noop" (short for "no operation" - ask your dad about assembler programming :-) You can put the noop actions in your userdata appcommand.xml.

Note the subtle difference between 1 and 2. If there is no action for an appcommand XBMC will ignore the appcommand and Windows gets it. If there is an action defined XBMC swallows the appcommand and executes that action, but the action can be "noop" to do nothing.

JR
Reply
#7
I edited the system appcommand.xml and it works perfectly, thanks!

Will that file get overwritten the next time I update xbmc?
Reply
#8
loki131 Wrote:Will that file get overwritten the next time I update xbmc?

Yes, I'm afraid so. I normally advise against editing the system files for exactly this reason, but appcommands are a special case.

JR
Reply
#9
ok All I want to do is make WM_Appcommand10 VOL Up Changed To Up and WM_appcommand9 be down Im in the appcommand keymap but not sure on how to change I also need to make it nolnger work in windows (Disable it so it nolonger controler volume just up and down. So I change <volume_down/>

to <volume_down/>down<volume_down/> and add noop or somthing

Please help Iv mapped everything else and im stuck on this
Reply
#10
stillapaco Wrote:ok All I want to do is make WM_Appcommand10 VOL Up Changed To Up and WM_appcommand9 be down

can you clarify what you're trying to do. Are you trying to make the volume appcommands change the XBMC volume, or are you trying to disable them completely so they don't change any voulme?

JR
Reply
#11
I have the acer RL100 and it has a Touch keyboard on it it has a scroll wheel on the side that controls Windows Volume I want it to A. Not Control Windows Volume and Instead Allow me to scroll through my movie collection now I scroll through my movie collection by hitting up and down on the keyboard I also want to be able to go up and down with the scroll wheel so Im preety sure I need to change WM_Appcommand10 (scroll wheel Up) to the Direction Up Button and The same for the WM_appcommand9 (scroll Wheel Down) To Direction Down Button. I know how to map my other keyboard commands but since the scroll wheel commands are app commands I need to change it in (system appcommand.xml) is that correctHuh I need to know what to change in Appcommand.XLM to make this work and Also Im worried that even If it works It will change my volume and I dont want my volume to go up and down while scrolling through my movie colletion I read the above Post


QUOTE:::::

You have two options:

1. ignore the appcommand and let Windows deal with it. For example the volume appcommands are treated this way so they control the Windows volume. To do this put the entry in as e.g. <volume_down/>. However note that you need to do this in the system appcommand.xml (even though I normally recommend not editing that!).

2. swallow the appcommand and do nothing. This means Windows won't receive the appcommand. To do this set the action to "noop" (short for "no operation" - ask your dad about assembler programming :-) You can put the noop actions in your userdata appcommand.xml.

Note the subtle difference between 1 and 2. If there is no action for an appcommand XBMC will ignore the appcommand and Windows gets it. If there is an action defined XBMC swallows the appcommand and executes that action, but the action can be "noop" to do nothing.

JR


SO Im Confused I just want to know what Lines of code I need to change and what it need to looks Like
Reply
#12
Press Windows-R and in the Run dialog type:

notepad "%appdata%\xbmc\userdata\keymaps\appcommand.xml"

and click OK. If you get prompted to create a new file answer Yes. Copy and paste the following into Notepad:

Code:
<keymap>
  <global>
    <appcommand>
      <volume_down>Down</volume_down>
      <volume_up>Up</volume_up>
    </appcommand>
  </global>
</keymap>

Close Notepad and save the changes. If you find it still doesn't work you need to enable debug logging and look at xbmc.log to find out what's going wrong. With the above appcommand.xml my log file shows:

Code:
DEBUG: WinEventsWin32.cpp: APPCOMMAND 9
DEBUG: CApplication::OnAppCommand: appcommand 9, trying action Down
DEBUG: WinEventsWin32.cpp: APPCOMMAND 10
DEBUG: CApplication::OnAppCommand: appcommand 10, trying action Up

Remember that this will only work in Eden. v10.1 doesn't support remapping of appcommand messages.

JR
Reply

Logout Mark Read Team Forum Stats Members Help
Button change in Eden0