How to generate key strokes events with the Input Subsystem
问题 I am writing a Key board emulator program in Linux, As a start I was able to render key strokes into X11 window but this is not working in virtual terminals and try out a different way. I referred to http://thiemonge.org/getting-started-with-uinput and tried with uinput kernel module. According to the tutorial key strokes can be injected as a uinput event and I wrote below code accordingly. #include <stdio.h> #include <stdlib.h> #include <string.h> #include <unistd.h> #include <fcntl.h>