keycode

Display terminal keycodes in various forms.

Contributed by
Larry Philps
Obtained from
News
Restrictions
Public Domain
Description
This simple program puts your teminal into raw mode, reads characters from standard input and displays the resulting codes in ASCII form, as well as decimal, octal, and hexadecimal. Very useful for finding out what escape sequences are sent by keys on a terminal.
Productivity
Everyone needs a program like this once in a while, having one saves you the 10 minutes needed to write one from scratch.
Safety
Only 50 lines of code which were examined for traps.
Work Planned
None.
Verification
Just run it.


Note that all this source is configured to be installed under /usr/skunk. To build it for a different location, compile with make CTRBDESTDIR=directory.