Open In App

showkey command in Linux with Examples

showkey command in Linux is used to examine the codes sent by the keyboard. showkey prints to standard output either the scan codes or the key code or the `ascii’ code of each key pressed. In the first two modes, the program runs until 10 seconds have elapsed since the last key press or release event, or until it receives a suitable signal, like SIGTERM, from another process. In `ascii’ mode the program terminates when the user types ^D.

Syntax:



showkey [-h|--help] [-a|--ascii] [-s|--scancodes] [-k|--keycodes]

Example: This will examine the codes sent by the keyboard.

sudo showkey



Options:

Article Tags :