Project

General

Profile

Actions

Submit #2921

open

Allow moused to accept userland mouse events

Added by tautolog almost 8 years ago. Updated almost 3 years ago.

Status:
New
Priority:
Normal
Assignee:
-
Category:
Userland
Target version:
Start date:
06/10/2016
Due date:
% Done:

0%

Estimated time:

Description

Allow moused to work with sysmouse when the port is a pipe,
not a real mouse device with working ioctls. Allows simple userland injection
of mouse events.

Attached is an example that works with the Griffin PowerMate
https://www.amazon.com/Griffin-Technology-NA16029-Multimedia-Controller/dp/B003VWU2WA/

Just run `./scrollwheel.py scroller.fifo` as a user account, and then run `moused -p scroller.fifo -t sysmouse` as root.

If you press down the wheel, it will multiply scrolls by 32, so you can fly through code like in the movies.


Files

0001-Allow-moused-to-work-with-sysmouse-when-the-port-is-.patch (1.41 KB) 0001-Allow-moused-to-work-with-sysmouse-when-the-port-is-.patch trivial fix for moused tautolog, 06/10/2016 02:30 PM
scrollwheel.py (2.8 KB) scrollwheel.py example that maps a volume knob USB HID device to scrolling mouse events tautolog, 06/10/2016 02:31 PM
Actions #1

Updated by tautolog almost 7 years ago

I cleaned up the PowerMate python generic USB Driver to also be able to use libxdo to send keyboard or mouse events to X. This should work on any platform with X, and bypasses the moused hack. However, I also left a moused option because it also works on the console. I also placed the code for it on github. https://github.com/legitparty/powermate

This makes the moused hack not really necessary, unless you want console support as well. But I still think the patch should be applied because it isn't just a "hack", because all it does is fix a couple of uncaught errors relating to ioctls not existing. The errors weren't really handled properly anyway. Before, the code just assumed that the ioctls worked. With the patch, it merely falls back to not breaking sysmouse protocol handling.

Actions #2

Updated by tuxillo almost 3 years ago

  • Target version changed from 4.2 to 6.0
Actions

Also available in: Atom PDF