Results 1 to 10 of 121

Thread: HOWTO: Logitech MX Revolution in Dapper

Threaded View

  1. #11
    Join Date
    Jun 2006
    Ubuntu Jaunty Jackalope (testing)

    Re: HOWTO: Logitech MX Revolution in Dapper

    I own a logitech G5 mouse now, which is an excellent mouse aswell.

    I've installed your program and it does well....nothing

    im pretty sure this is due to the fact that my mouse sends out what you call rawcodes in
    your program that i haven't configured yet.

    Can you tell me how i can lookup what the rawcodes are for my mouse? (i think it's xev)
    For the G5 the program would need a bit more than just the rawcode changes. I did, however, code some parts so that it could be used for other mice as well. This means that support for the G5 could possibly be added with little effort.

    So if you (or anyone else for that matter) want support for a different mouse, I will need the following things:

    1. The complete output of your /proc/bus/input/devices file.

    $ cat /proc/bus/input/devices > ~/devices_output
    If you have multiple mice connected, please tell me which one of the sections refers to the mouse you want support for. From that file, I need to know the Vendor and Product IDs, and possibly the Handler line for each of the sections that refers to the mouse (MX and VX have two sections, one being simply for the search button). Most likely just sending the output will do fine.

    2. This is the trickier bit and might take a little explaining. I need you to hexdump your event handler output.
    First, you need to find out the event name to look at. This can be found in the previously mentioned /proc/bus/input/devices file. You need to know the Vendor and Product ID for your mouse. If you don't know them, google them. If you still can't find them, look at the bottom of the post for additional instructions.

    Here is the output for my mouse:

    I: Bus=0003 Vendor=046d Product=c51a Version=0111
    N: Name="Logitech USB Receiver"
    P: Phys=usb-0000:00:02.0-4/input0
    S: Sysfs=/class/input/input7
    H: Handlers=mouse2 ts2 event3 
    B: EV=7
    B: KEY=ffff0000 0 0 0 0 0 0 0 0
    B: REL=143
    The bolded part is the important bit. This is the event name you need for the next step.

    3. Now starts the actual hexdumping. Run the following command, replacing "event3" with the event name you got in the previous step:

    $ sudo cat /dev/input/event3 | hexdump
    Now you get lots of hexadecimal code running across your screen whenever you do something with your mouse. Now, for each button on your mouse, copy down exactly what happens. Try clicking a button several times until you are sure that a certain couple of lines refer to exactly that button.

    For example, when I press and release the thumb mouse wheel on my MX Revo, I get the following 4 lines:

    00029f0 7d62 4658 240d 0008 0001 011c 0001 0000
    0002a00 7d62 4658 2412 0008 0000 0000 0000 0000
    0002a10 7d63 4658 68d0 0005 0001 011c 0000 0000
    0002a20 7d63 4658 68d4 0005 0000 0000 0000 0000
    The first and the third lines are important. Notice how they are almost the same. The first one is for pressing and the third one is for releasing the button. The rawcode is actually 4 bytes in that line. You can stop the program by pressing Ctrl-C so you don't lose track of which lines referred to a certain button. For each button, I would like something like this:

    Thumb wheel press
    00029f0 7d62 4658 240d 0008 0001 011c 0001 0000   press
    0002a00 7d62 4658 2412 0008 0000 0000 0000 0000
    0002a10 7d63 4658 68d0 0005 0001 011c 0000 0000  release
    0002a20 7d63 4658 68d4 0005 0000 0000 0000 0000
    Some buttons only register a press event and no release. You will notice this when you only get two lines on hexdump, or that the lines always stay the same. This is very important information for me, otherwise the button won't work. This is the case for my top wheel tilt events. When this happens, I would like the following information:

    Top wheel tilt left (no release event)
    0000840 7fd7 4658 8545 000e 0002 0006 ffff ffff    press
    0000850 7fd7 4658 8548 000e 0000 0000 0000 0000
    And that's pretty much it. Stick all the hexdumps with comments in a file and send them to me.

    ------------------- Can't find Vendor and Product ID? -----------------------

    Run the following command:
    $ ls /dev/input
    Now run
    $ sudo cat /dev/input/eventX | hexdump
    for each event listed by ls in that folder, replacing X with the different numbers. Once you see output when you move your mouse or press its buttons, you've found it. It might not be necessary at this point, but you can now look at the /proc/bus/input/devices and find the section with that event name in its handler. That section's Vendor and Product IDs are for your mouse.

    I'm willing to test anything you want and givefeeback in order to make your program more universal.
    I hope the length of the post hasn't changed your mind . But on a more serious note, I'm glad you feel this way. The reason Linux and its distros are becoming such excellent pieces of software (or should I call them artwork), is because there are people with a passion to help and share to make it better. Try finding that on a Windows forum. Even theír hired staff won't help as much as the Linux community. I owe a lot to Linux and I'm glad to be able to give something back.

    If someone feels confident coding C and is interested in supporting the program, I can give commit privileges to the SVN repository.
    Last edited by daou; May 26th, 2007 at 08:19 PM.
    echo -e "\x6f\x61\x73\x61\x6c\x6f\x6e\x65\x6e\x40\x67 \b\x6d\x61\x69\x6c\x2e\x63\x6f\x6d"
    It compiles! Ship it!


Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts