3

Since that every things is a file on the UNIX system. If I have a hardware, for example, a mouse, move from left corner to right corner, it should produce some kinds of file to communicate with the system.

So, if my assumption is correct, is this possible to do following things:

  1. Capture the raw data, which is about moving mouse cursor from left corner to right corner?

  2. Reduplicate the raw data, using a program, same producing speed, and data, in order to "redo" moving mouse cursor from left corner to right corner

Joachim Sauer
  • 10,956
  • 3
  • 52
  • 45
Ted Wong
  • 1,589
  • 1
  • 15
  • 19

1 Answers1

2

Yes you can capture "raw" mouse events using the /dev/input/* device nodes. You can then replay those events by writing an application that interfaces with the uinput driver.

You can also do this with the XServer by subscribing to mouse events on the root window and using the xtest extension to replay the events.

ssgriffonuser
  • 361
  • 2
  • 4