Question about simulating a MT device with evemu-event
Peter Hutterer
peter.hutterer at who-t.net
Mon Nov 30 10:38:06 UTC 2020
On Mon, Nov 30, 2020 at 10:09:29AM +0100, input-tools at storiepvtride.it wrote:
>
> Peter Hutterer writes:
> >
> > This is all you're simulating - finger down at that location. To get pointer
> > events you need to start moving the touch point in consecutive events, and
> > eventually release it.
>
> I didn't mention that my test bash script has +7000 events :-) I
> understand that one "block" of events is not visible, I just expected
> even a single event to appear in `libinput debug-events`.
>
> But I understand that I need to send "complete" and well-formed events in
> order to be understood and detected.
>
> My end goal is simply to mimick a mouse using a keyboard, so it will
> probably make more sense to send EV_REL events.
yeah, definitely. the MT protocol has a lot of cornercases and you need to
make sure the state of the device is correct at all times. much easier to
just send EV_REL events which are handled as-is instead.o
Cheers,
Peter
>
> > Have a read of this post to get a better understanding of how evdev works:
> > https://who-t.blogspot.com/2016/09/understanding-evdev.html
> >
> > fwiw, I strongly recommend using python-libevdev over evemu-event. murch
> > more flexible.
>
> Ah great, that's a great resource. I will experiment more with a proper
> library, I am using bash just for testing.
>
> Thank you so much for the tips and for the fantastic work on libinput!
>
> Cheers,
> _______________________________________________
> Input-tools mailing list
> Input-tools at lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/input-tools
More information about the Input-tools
mailing list