KBDINFO(1)

๐Ÿ“ฆ
version 2.10.0 ยท 3 versions
, in alpine 3.22, alpine 3.23, alpine 3.24, arch rolling, fedora 43, fedora 44, nixos 26.05, nixpkgs unstable, opensuse-leap 16.0

๐Ÿ’– KBDINFO(1) ๐Ÿ’–

okay bestie, so this is kbdinfo from the General Commands Manual โ€” she's a lil utility that reads your keyboard's whole situation and your virtual console's vibe. no cap, she's the nosy bestie who knows everything about your keyboard state and is not sorry about it ๐Ÿ’…


โœจ NAME โœจ

kbdinfo โ€” read information about keyboard state ๐Ÿ”โŒจ๏ธ


๐Ÿฆ‹ SYNOPSIS ๐Ÿฆ‹

kbdinfo [options] getmode [text|graphics]
kbdinfo [options] gkbmode [raw|xlate|mediumraw|unicode]
kbdinfo [options] gkbmeta [metabit|escprefix]
kbdinfo [options] gkbled  [scrolllock|numlock|capslock]

๐ŸŒธ DESCRIPTION ๐ŸŒธ

so basically this utility lets you read and check a bunch of different parameters of the keyboard and the virtual console. it's giving "let me look at you, let me really look at you" ๐Ÿซถ

  • getmode โ€” get or check the virtual console mode. that's it, that's the whole job.
  • gkbmode โ€” gets the current keyboard mode. here's the tea on what those modes actually are:
    • raw โ€” Raw (scancode) mode. these are the raw codes generated by the keyboard. unprocessed, unfiltered, straight off the presses ๐ŸŽ€
    • mediumraw โ€” Medium raw (scancode) mode. this is extended medium raw mode, with keys above 127 encoded as 0, high 7 bits, low 7 bits, with the 0 bearing the 'up' flag if needed. 0 is reserved, so this shouldn't interfere with anything else. the two bytes after 0 will always have the up flag set not to interfere with older applications. this allows for 16384 different keycodes, which should be enough. (iconic of them to just say "should be enough" honestly ๐Ÿ˜ญ)
    • xlate โ€” Translate keycodes using keymap. these are the codes generated via the current keysym mapping.
    • unicode โ€” Unicode mode. exactly what it says on the tin โœจ
  • gkbmeta โ€” gets meta key handling mode. two flavours:
    • escprefix โ€” specifies if pressing the meta (alt) key generates an ESC (\033) prefix followed by the keysym.
    • metabit โ€” the keysym marked with the high bit set.
  • gkbled โ€” get keyboard flags CapsLock, NumLock, ScrollLock (not lights, bestie, flags โ€” we're reading state, not staring at your lil LEDs ๐Ÿ’€). which one is down:
    • scrolllock โ€” the scroll lock is down.
    • numlock โ€” the num lock is down.
    • capslock โ€” the caps lock is down.

๐Ÿ‘‘ OPTIONS ๐Ÿ‘‘

  • -C, --console=DEV โ€” the console device to be used. pick your console, main character energy ๐ŸŽฎ
  • -V, --version โ€” print version number. slay, who are you โœจ
  • -h, --help โ€” print this usage message. the classic cry for help ๐Ÿซถ

๐Ÿงš AUTHORS ๐Ÿงš

Written by Alexey Gladkov. respect, thank you for your service ๐Ÿซก๐Ÿ’œ


๐ŸŒˆ SEE ALSO ๐ŸŒˆ

kbdrate(1), setleds(1), kbd_mode(1)

the whole friend group honestly, go say hi to all of them ๐Ÿฆ‹


kbd ยท June 2019 โ€” that's the source, the version, and the date bestie, and that's the whole page, you ate it up fr fr ๐Ÿ’…๐Ÿ’– no cap, go check your keyboard mode, she's waiting for you ๐ŸŒธ