Mapping extra mmo mouse side buttons











up vote
0
down vote

favorite












I've recently purchased the Utechsmart Venus mouse: http://www.utechsmart.com/product/show/id/477/US-D16400-GM



I've been unable to bind those side buttons (and the "rapid fire button near the left mouse button) to different keys without changing the keys the side and rapidfire buttons point to.



The reason for this is that I've been unable to actually get xev to recognize the side and rapid fire buttons as their own event. Instead, when I press a side button or rapid fire button, the xev event tester immediately reports the binding that the button is mapped to.



I.e. I press side button "1", event mapper reports:



 KeyPress event, serial 74, . . .
KeyRelease event, serial 74 . . .


When I press the left mouse button the mapper reports:



 ButtonPress event, serial 37, . . .
Button Release event, serial 37, . . .


Obviously I can't map the button from the mouse if its not telling me what the button "address" is as in these two related posts:



How to configure extra buttons in Logitech Mouse



Mouse shortcuts get confused with keyboard keys in Kubuntu



Does anyone have any advice to further try and find out what these buttons are on the mouse?



Obviously the mouse is working, its just not mapped to buttons in a way that I would prefer. Therefore it seems to me that there must to be a solution to this, and I'd be more than happy to dive quite deeply to solve this problem. I've been looking at the documentation for Xorg and evdev drivers, but I'm not even certain if that's the correct direction.



Not necessarily looking for someone to solve this problem directly for me. But helping me to brainstorm for some ideas about how to go about solving this problem would be greatly appreciated.



Thanks for your patience!



UPDATE:



So I've found a post on archlinux forums about the razer naga which is a very similar mouse. It seems hopeful: https://bbs.archlinux.org/viewtopic.php?id=145502. That lead me to a similar problem with infrared remote controls here: enter link description here. There is a wealth of information there that goes into decent depth about the issue. It would be nice if they explained better how they figure out what the "keys" are in the scripts, but after reading a lot of the suplementary material it seems that the is coming from convention (and since the buttons on the mouse correspond to those key mappings it only makes further sense. . .



However, I'm still having a bit of an issue. I haven't created a shebang yet, instead I've just tried to run the command by hand.



First I created the symbols file /usr/share/X11/xkb/symbols/custom (I'm not quite sure why they're using the tmp directory) and included the following:



xkb_symbols "venus" {
2 key <AE01> { [ y, Y ]
3 key <AE02> { [ i, I ]
4 key <AE03> { [bracketleft, braceleft ]
5 key <AE04> { [bracketright, braceright ]
6 key <AE05> { [ slash, question ]
7 key <AE06> { [ j, J ]
8 key <AE07> { [ k, K ]
9 key <AE08> { [ l, L ]
10 key <AE09> { [ semicolon, colon ]
11 key <AE10> { [ comma, less ]
12 key <AE11> { [ minus, underscore ]
13 key <AE12> { [ equal, plus ]
14 };


Then I ran xinput list which yeilded:



⎡ Virtual core pointer                      id=2    [master pointer  (3)]
⎜ ↳ Virtual core XTEST pointer id=4 [slave pointer (2)]
⎜ ↳ USB Laser Game Mouse id=9 [slave pointer (2)]
⎜ ↳ USB Laser Game Mouse id=11 [slave pointer (2)]
⎜ ↳ EST Gaming keyboard id=13 [slave pointer (2)]
⎣ Virtual core keyboard id=3 [master keyboard (2)]
↳ Virtual core XTEST keyboard id=5 [slave keyboard (3)]
↳ Power Button id=6 [slave keyboard (3)]
↳ Power Button id=7 [slave keyboard (3)]
↳ Sleep Button id=8 [slave keyboard (3)]
↳ USB Laser Game Mouse id=10 [slave keyboard (3)]
↳ EST Gaming keyboard id=12 [slave keyboard (3)]
↳ EST Gaming keyboard id=14 [slave keyboard (3)]
↳ C-Media Electronics Inc. USB Audio Device id=15 [slave keyboard (3)]
↳ USB Laser Game Mouse id=16 [slave keyboard (3)]
↳ EST Gaming keyboard id=17 [slave keyboard (3)]


After analyzing the script written in the two links above, I deduced that my $remote_id variable would be 16 so I ran the following:



setxkbmap -device 16 -print | sed's/(xkb_symbols.*)"/1+custom(venus)"/' | xkbcomp -I /usr/share/X11/xkb -i 16 -synch $DISPLAY


I did not pipe my output into /dev/null because I wanted to see what the output would be (obviously when I make the script, then I will do this, but I'm trying to understand what I'm doing at the moment). My output was the following:



Warning:          Too many file names on command line
Compiling /usr/share/X11/xkb, writing to -, ignoring :0
syntax error: line 1 of /usr/share/X11/xkb
last scanned symbol is:
Errors encountered in /usr/share/X11/xkb; not compiled.


I'm not really sure where to go from here. . .










share|improve this question









New contributor




Nicholas R is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
























    up vote
    0
    down vote

    favorite












    I've recently purchased the Utechsmart Venus mouse: http://www.utechsmart.com/product/show/id/477/US-D16400-GM



    I've been unable to bind those side buttons (and the "rapid fire button near the left mouse button) to different keys without changing the keys the side and rapidfire buttons point to.



    The reason for this is that I've been unable to actually get xev to recognize the side and rapid fire buttons as their own event. Instead, when I press a side button or rapid fire button, the xev event tester immediately reports the binding that the button is mapped to.



    I.e. I press side button "1", event mapper reports:



     KeyPress event, serial 74, . . .
    KeyRelease event, serial 74 . . .


    When I press the left mouse button the mapper reports:



     ButtonPress event, serial 37, . . .
    Button Release event, serial 37, . . .


    Obviously I can't map the button from the mouse if its not telling me what the button "address" is as in these two related posts:



    How to configure extra buttons in Logitech Mouse



    Mouse shortcuts get confused with keyboard keys in Kubuntu



    Does anyone have any advice to further try and find out what these buttons are on the mouse?



    Obviously the mouse is working, its just not mapped to buttons in a way that I would prefer. Therefore it seems to me that there must to be a solution to this, and I'd be more than happy to dive quite deeply to solve this problem. I've been looking at the documentation for Xorg and evdev drivers, but I'm not even certain if that's the correct direction.



    Not necessarily looking for someone to solve this problem directly for me. But helping me to brainstorm for some ideas about how to go about solving this problem would be greatly appreciated.



    Thanks for your patience!



    UPDATE:



    So I've found a post on archlinux forums about the razer naga which is a very similar mouse. It seems hopeful: https://bbs.archlinux.org/viewtopic.php?id=145502. That lead me to a similar problem with infrared remote controls here: enter link description here. There is a wealth of information there that goes into decent depth about the issue. It would be nice if they explained better how they figure out what the "keys" are in the scripts, but after reading a lot of the suplementary material it seems that the is coming from convention (and since the buttons on the mouse correspond to those key mappings it only makes further sense. . .



    However, I'm still having a bit of an issue. I haven't created a shebang yet, instead I've just tried to run the command by hand.



    First I created the symbols file /usr/share/X11/xkb/symbols/custom (I'm not quite sure why they're using the tmp directory) and included the following:



    xkb_symbols "venus" {
    2 key <AE01> { [ y, Y ]
    3 key <AE02> { [ i, I ]
    4 key <AE03> { [bracketleft, braceleft ]
    5 key <AE04> { [bracketright, braceright ]
    6 key <AE05> { [ slash, question ]
    7 key <AE06> { [ j, J ]
    8 key <AE07> { [ k, K ]
    9 key <AE08> { [ l, L ]
    10 key <AE09> { [ semicolon, colon ]
    11 key <AE10> { [ comma, less ]
    12 key <AE11> { [ minus, underscore ]
    13 key <AE12> { [ equal, plus ]
    14 };


    Then I ran xinput list which yeilded:



    ⎡ Virtual core pointer                      id=2    [master pointer  (3)]
    ⎜ ↳ Virtual core XTEST pointer id=4 [slave pointer (2)]
    ⎜ ↳ USB Laser Game Mouse id=9 [slave pointer (2)]
    ⎜ ↳ USB Laser Game Mouse id=11 [slave pointer (2)]
    ⎜ ↳ EST Gaming keyboard id=13 [slave pointer (2)]
    ⎣ Virtual core keyboard id=3 [master keyboard (2)]
    ↳ Virtual core XTEST keyboard id=5 [slave keyboard (3)]
    ↳ Power Button id=6 [slave keyboard (3)]
    ↳ Power Button id=7 [slave keyboard (3)]
    ↳ Sleep Button id=8 [slave keyboard (3)]
    ↳ USB Laser Game Mouse id=10 [slave keyboard (3)]
    ↳ EST Gaming keyboard id=12 [slave keyboard (3)]
    ↳ EST Gaming keyboard id=14 [slave keyboard (3)]
    ↳ C-Media Electronics Inc. USB Audio Device id=15 [slave keyboard (3)]
    ↳ USB Laser Game Mouse id=16 [slave keyboard (3)]
    ↳ EST Gaming keyboard id=17 [slave keyboard (3)]


    After analyzing the script written in the two links above, I deduced that my $remote_id variable would be 16 so I ran the following:



    setxkbmap -device 16 -print | sed's/(xkb_symbols.*)"/1+custom(venus)"/' | xkbcomp -I /usr/share/X11/xkb -i 16 -synch $DISPLAY


    I did not pipe my output into /dev/null because I wanted to see what the output would be (obviously when I make the script, then I will do this, but I'm trying to understand what I'm doing at the moment). My output was the following:



    Warning:          Too many file names on command line
    Compiling /usr/share/X11/xkb, writing to -, ignoring :0
    syntax error: line 1 of /usr/share/X11/xkb
    last scanned symbol is:
    Errors encountered in /usr/share/X11/xkb; not compiled.


    I'm not really sure where to go from here. . .










    share|improve this question









    New contributor




    Nicholas R is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
    Check out our Code of Conduct.






















      up vote
      0
      down vote

      favorite









      up vote
      0
      down vote

      favorite











      I've recently purchased the Utechsmart Venus mouse: http://www.utechsmart.com/product/show/id/477/US-D16400-GM



      I've been unable to bind those side buttons (and the "rapid fire button near the left mouse button) to different keys without changing the keys the side and rapidfire buttons point to.



      The reason for this is that I've been unable to actually get xev to recognize the side and rapid fire buttons as their own event. Instead, when I press a side button or rapid fire button, the xev event tester immediately reports the binding that the button is mapped to.



      I.e. I press side button "1", event mapper reports:



       KeyPress event, serial 74, . . .
      KeyRelease event, serial 74 . . .


      When I press the left mouse button the mapper reports:



       ButtonPress event, serial 37, . . .
      Button Release event, serial 37, . . .


      Obviously I can't map the button from the mouse if its not telling me what the button "address" is as in these two related posts:



      How to configure extra buttons in Logitech Mouse



      Mouse shortcuts get confused with keyboard keys in Kubuntu



      Does anyone have any advice to further try and find out what these buttons are on the mouse?



      Obviously the mouse is working, its just not mapped to buttons in a way that I would prefer. Therefore it seems to me that there must to be a solution to this, and I'd be more than happy to dive quite deeply to solve this problem. I've been looking at the documentation for Xorg and evdev drivers, but I'm not even certain if that's the correct direction.



      Not necessarily looking for someone to solve this problem directly for me. But helping me to brainstorm for some ideas about how to go about solving this problem would be greatly appreciated.



      Thanks for your patience!



      UPDATE:



      So I've found a post on archlinux forums about the razer naga which is a very similar mouse. It seems hopeful: https://bbs.archlinux.org/viewtopic.php?id=145502. That lead me to a similar problem with infrared remote controls here: enter link description here. There is a wealth of information there that goes into decent depth about the issue. It would be nice if they explained better how they figure out what the "keys" are in the scripts, but after reading a lot of the suplementary material it seems that the is coming from convention (and since the buttons on the mouse correspond to those key mappings it only makes further sense. . .



      However, I'm still having a bit of an issue. I haven't created a shebang yet, instead I've just tried to run the command by hand.



      First I created the symbols file /usr/share/X11/xkb/symbols/custom (I'm not quite sure why they're using the tmp directory) and included the following:



      xkb_symbols "venus" {
      2 key <AE01> { [ y, Y ]
      3 key <AE02> { [ i, I ]
      4 key <AE03> { [bracketleft, braceleft ]
      5 key <AE04> { [bracketright, braceright ]
      6 key <AE05> { [ slash, question ]
      7 key <AE06> { [ j, J ]
      8 key <AE07> { [ k, K ]
      9 key <AE08> { [ l, L ]
      10 key <AE09> { [ semicolon, colon ]
      11 key <AE10> { [ comma, less ]
      12 key <AE11> { [ minus, underscore ]
      13 key <AE12> { [ equal, plus ]
      14 };


      Then I ran xinput list which yeilded:



      ⎡ Virtual core pointer                      id=2    [master pointer  (3)]
      ⎜ ↳ Virtual core XTEST pointer id=4 [slave pointer (2)]
      ⎜ ↳ USB Laser Game Mouse id=9 [slave pointer (2)]
      ⎜ ↳ USB Laser Game Mouse id=11 [slave pointer (2)]
      ⎜ ↳ EST Gaming keyboard id=13 [slave pointer (2)]
      ⎣ Virtual core keyboard id=3 [master keyboard (2)]
      ↳ Virtual core XTEST keyboard id=5 [slave keyboard (3)]
      ↳ Power Button id=6 [slave keyboard (3)]
      ↳ Power Button id=7 [slave keyboard (3)]
      ↳ Sleep Button id=8 [slave keyboard (3)]
      ↳ USB Laser Game Mouse id=10 [slave keyboard (3)]
      ↳ EST Gaming keyboard id=12 [slave keyboard (3)]
      ↳ EST Gaming keyboard id=14 [slave keyboard (3)]
      ↳ C-Media Electronics Inc. USB Audio Device id=15 [slave keyboard (3)]
      ↳ USB Laser Game Mouse id=16 [slave keyboard (3)]
      ↳ EST Gaming keyboard id=17 [slave keyboard (3)]


      After analyzing the script written in the two links above, I deduced that my $remote_id variable would be 16 so I ran the following:



      setxkbmap -device 16 -print | sed's/(xkb_symbols.*)"/1+custom(venus)"/' | xkbcomp -I /usr/share/X11/xkb -i 16 -synch $DISPLAY


      I did not pipe my output into /dev/null because I wanted to see what the output would be (obviously when I make the script, then I will do this, but I'm trying to understand what I'm doing at the moment). My output was the following:



      Warning:          Too many file names on command line
      Compiling /usr/share/X11/xkb, writing to -, ignoring :0
      syntax error: line 1 of /usr/share/X11/xkb
      last scanned symbol is:
      Errors encountered in /usr/share/X11/xkb; not compiled.


      I'm not really sure where to go from here. . .










      share|improve this question









      New contributor




      Nicholas R is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
      Check out our Code of Conduct.











      I've recently purchased the Utechsmart Venus mouse: http://www.utechsmart.com/product/show/id/477/US-D16400-GM



      I've been unable to bind those side buttons (and the "rapid fire button near the left mouse button) to different keys without changing the keys the side and rapidfire buttons point to.



      The reason for this is that I've been unable to actually get xev to recognize the side and rapid fire buttons as their own event. Instead, when I press a side button or rapid fire button, the xev event tester immediately reports the binding that the button is mapped to.



      I.e. I press side button "1", event mapper reports:



       KeyPress event, serial 74, . . .
      KeyRelease event, serial 74 . . .


      When I press the left mouse button the mapper reports:



       ButtonPress event, serial 37, . . .
      Button Release event, serial 37, . . .


      Obviously I can't map the button from the mouse if its not telling me what the button "address" is as in these two related posts:



      How to configure extra buttons in Logitech Mouse



      Mouse shortcuts get confused with keyboard keys in Kubuntu



      Does anyone have any advice to further try and find out what these buttons are on the mouse?



      Obviously the mouse is working, its just not mapped to buttons in a way that I would prefer. Therefore it seems to me that there must to be a solution to this, and I'd be more than happy to dive quite deeply to solve this problem. I've been looking at the documentation for Xorg and evdev drivers, but I'm not even certain if that's the correct direction.



      Not necessarily looking for someone to solve this problem directly for me. But helping me to brainstorm for some ideas about how to go about solving this problem would be greatly appreciated.



      Thanks for your patience!



      UPDATE:



      So I've found a post on archlinux forums about the razer naga which is a very similar mouse. It seems hopeful: https://bbs.archlinux.org/viewtopic.php?id=145502. That lead me to a similar problem with infrared remote controls here: enter link description here. There is a wealth of information there that goes into decent depth about the issue. It would be nice if they explained better how they figure out what the "keys" are in the scripts, but after reading a lot of the suplementary material it seems that the is coming from convention (and since the buttons on the mouse correspond to those key mappings it only makes further sense. . .



      However, I'm still having a bit of an issue. I haven't created a shebang yet, instead I've just tried to run the command by hand.



      First I created the symbols file /usr/share/X11/xkb/symbols/custom (I'm not quite sure why they're using the tmp directory) and included the following:



      xkb_symbols "venus" {
      2 key <AE01> { [ y, Y ]
      3 key <AE02> { [ i, I ]
      4 key <AE03> { [bracketleft, braceleft ]
      5 key <AE04> { [bracketright, braceright ]
      6 key <AE05> { [ slash, question ]
      7 key <AE06> { [ j, J ]
      8 key <AE07> { [ k, K ]
      9 key <AE08> { [ l, L ]
      10 key <AE09> { [ semicolon, colon ]
      11 key <AE10> { [ comma, less ]
      12 key <AE11> { [ minus, underscore ]
      13 key <AE12> { [ equal, plus ]
      14 };


      Then I ran xinput list which yeilded:



      ⎡ Virtual core pointer                      id=2    [master pointer  (3)]
      ⎜ ↳ Virtual core XTEST pointer id=4 [slave pointer (2)]
      ⎜ ↳ USB Laser Game Mouse id=9 [slave pointer (2)]
      ⎜ ↳ USB Laser Game Mouse id=11 [slave pointer (2)]
      ⎜ ↳ EST Gaming keyboard id=13 [slave pointer (2)]
      ⎣ Virtual core keyboard id=3 [master keyboard (2)]
      ↳ Virtual core XTEST keyboard id=5 [slave keyboard (3)]
      ↳ Power Button id=6 [slave keyboard (3)]
      ↳ Power Button id=7 [slave keyboard (3)]
      ↳ Sleep Button id=8 [slave keyboard (3)]
      ↳ USB Laser Game Mouse id=10 [slave keyboard (3)]
      ↳ EST Gaming keyboard id=12 [slave keyboard (3)]
      ↳ EST Gaming keyboard id=14 [slave keyboard (3)]
      ↳ C-Media Electronics Inc. USB Audio Device id=15 [slave keyboard (3)]
      ↳ USB Laser Game Mouse id=16 [slave keyboard (3)]
      ↳ EST Gaming keyboard id=17 [slave keyboard (3)]


      After analyzing the script written in the two links above, I deduced that my $remote_id variable would be 16 so I ran the following:



      setxkbmap -device 16 -print | sed's/(xkb_symbols.*)"/1+custom(venus)"/' | xkbcomp -I /usr/share/X11/xkb -i 16 -synch $DISPLAY


      I did not pipe my output into /dev/null because I wanted to see what the output would be (obviously when I make the script, then I will do this, but I'm trying to understand what I'm doing at the moment). My output was the following:



      Warning:          Too many file names on command line
      Compiling /usr/share/X11/xkb, writing to -, ignoring :0
      syntax error: line 1 of /usr/share/X11/xkb
      last scanned symbol is:
      Errors encountered in /usr/share/X11/xkb; not compiled.


      I'm not really sure where to go from here. . .







      mouse remapping






      share|improve this question









      New contributor




      Nicholas R is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
      Check out our Code of Conduct.











      share|improve this question









      New contributor




      Nicholas R is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
      Check out our Code of Conduct.









      share|improve this question




      share|improve this question








      edited Nov 24 at 4:44





















      New contributor




      Nicholas R is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
      Check out our Code of Conduct.









      asked Nov 23 at 16:48









      Nicholas R

      11




      11




      New contributor




      Nicholas R is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
      Check out our Code of Conduct.





      New contributor





      Nicholas R is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
      Check out our Code of Conduct.






      Nicholas R is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
      Check out our Code of Conduct.



























          active

          oldest

          votes











          Your Answer








          StackExchange.ready(function() {
          var channelOptions = {
          tags: "".split(" "),
          id: "89"
          };
          initTagRenderer("".split(" "), "".split(" "), channelOptions);

          StackExchange.using("externalEditor", function() {
          // Have to fire editor after snippets, if snippets enabled
          if (StackExchange.settings.snippets.snippetsEnabled) {
          StackExchange.using("snippets", function() {
          createEditor();
          });
          }
          else {
          createEditor();
          }
          });

          function createEditor() {
          StackExchange.prepareEditor({
          heartbeatType: 'answer',
          convertImagesToLinks: true,
          noModals: true,
          showLowRepImageUploadWarning: true,
          reputationToPostImages: 10,
          bindNavPrevention: true,
          postfix: "",
          imageUploader: {
          brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
          contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
          allowUrls: true
          },
          onDemand: true,
          discardSelector: ".discard-answer"
          ,immediatelyShowMarkdownHelp:true
          });


          }
          });






          Nicholas R is a new contributor. Be nice, and check out our Code of Conduct.










           

          draft saved


          draft discarded


















          StackExchange.ready(
          function () {
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f1095437%2fmapping-extra-mmo-mouse-side-buttons%23new-answer', 'question_page');
          }
          );

          Post as a guest















          Required, but never shown






























          active

          oldest

          votes













          active

          oldest

          votes









          active

          oldest

          votes






          active

          oldest

          votes








          Nicholas R is a new contributor. Be nice, and check out our Code of Conduct.










           

          draft saved


          draft discarded


















          Nicholas R is a new contributor. Be nice, and check out our Code of Conduct.













          Nicholas R is a new contributor. Be nice, and check out our Code of Conduct.












          Nicholas R is a new contributor. Be nice, and check out our Code of Conduct.















           


          draft saved


          draft discarded














          StackExchange.ready(
          function () {
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f1095437%2fmapping-extra-mmo-mouse-side-buttons%23new-answer', 'question_page');
          }
          );

          Post as a guest















          Required, but never shown





















































          Required, but never shown














          Required, but never shown












          Required, but never shown







          Required, but never shown

































          Required, but never shown














          Required, but never shown












          Required, but never shown







          Required, but never shown







          Popular posts from this blog

          How did Captain America manage to do this?

          迪纳利

          南乌拉尔铁路局