I have a USB numpad that I want to use to control a specific application running as a daemon in the background. The daemon is written in Python and I'm currently reading input using python-evdev
which works quite well.
However, everything I type on the keyboard is still also processed normally, meaning that keypresses are also inserted into any application dealing with keyboard input (including the login prompt that is shown when the computer boots up). This is somewhat annoying.
Is there a way to disable the "normal" processing of keyboard events, and only allow manual reading of the key states? Hopefully one that does not depend on running X.
Everything I've found so far seems to be dealing with disabling the keyboard completely or using X.
One idea I have is to create a keymap which maps all the keys to dead keys, which prevents any output, but still allows me to read the actual keycodes. However, it seems that there should be an easier solution to this problem.