KBDCONTROL(1) | MidnightBSD General Commands Manual | KBDCONTROL(1) |
kbdcontrol
—
keyboard control and configuration utility
kbdcontrol |
[-dFKix ] [-A
name] [-a
name] [-b
duration.pitch |
belltype] [-r
delay.repeat |
speed] [-l
keymap_file] [-f
# string]
[-k keyboard_device]
[-L keymap_file]
[-P path] |
The kbdcontrol
command is used to set
various keyboard related options for the
syscons(4) or
vt(4) console driver and the
keyboard drivers, such as key map, keyboard repeat and delay rates, bell
characteristics etc.
Keyboard options may be automatically configured at system boot time by setting variables in /etc/rc.conf. See Boot Time Configuration below.
The following command line options are supported:
-A
namekbdcontrol
process should be redirected from the
keyboard multiplexer keyboard device (if the keyboard multiplexer is not
the active keyboard) or /dev/console (if the
keyboard multiplexer is the active keyboard and you are not working on the
system console).-a
namekbdcontrol
process should be redirected from the
keyboard multiplexer keyboard device (if the keyboard multiplexer is not
the active keyboard) or /dev/console (if the
keyboard multiplexer is the active keyboard and you are not working on the
system console).-b
duration.pitch |
belltypenormal
which sets sound parameters back to normal
values, off
which disables the bell entirely, or
visual
which sets the bell to visual mode, i.e.,
flashes the screen instead. If belltype is preceded
by the word quiet.
, the bell will not be rung when
the ringing process is in the background vty. The
visual
bell, when chosen, applies to all vtys;
other bell types can be set individually for each vty.-r
delay.repeat |
speedslow
(1000.504), fast
(250.34) or
normal
(500.126).-l
keymap_file-d
-l
option above.-f
# string-F
-x
-i
-K
-k
option below to associate a keyboard with the
console again.-k
keyboard_devicekbdcontrol
process
should be redirected from /dev/console if you are
not working on the system console (see the
EXAMPLES section).-L
keymap_file-P
path-P
option may be specified multiple times.The environment variable KEYMAP_PATH
can
hold an alternative path to the keyboard map files.
You may set variables in /etc/rc.conf or /etc/rc.conf.local in order to configure the keyboard at boot time. The following is the list of relevant variables.
-l
option.-r
option.-f
option.See rc.conf(5) for details.
The keyboard device driver may let you change default configuration options, such as the default keyboard map, so that you do not need to set up the options at boot time. See keyboard driver manuals (e.g. atkbd(4), ukbd(4)) for details.
The following command will load the keyboard map file /usr/share/syscons/keymaps/ru.koi8-r.kbd.
kbdcontrol -l
/usr/share/syscons/keymaps/ru.koi8-r.kbd
So long as the keyboard map file resides in /usr/share/syscons/keymaps (if using syscons(4)) or /usr/share/vt/keymaps (if using vt(4)), you may abbreviate the file name as ru.koi8-r. Since vt(4) uses Unicode, the corresponding keyboard file names omit the encoding and typically are just a country code, e.g. ru.
kbdcontrol -l ru.koi8-r
The following command will make the function key 10 emit "telnet myhost".
kbdcontrol -f 10 "telnet
myhost"
In order to get the visual effect for bell, but prevent the screen from flashing if the bell is to ring in the background screen, run the following command.
kbdcontrol -b
quiet.visual
To change the default console keyboard to another keyboard, for example the first USB keyboard (see ukbd(4)), use the following command.
kbdcontrol -k /dev/ukbd0 <
/dev/console
To switch back to the default keyboard, use this command.
kbdcontrol -k /dev/kbd0
To allow using both the second USB keyboard and the first AT keyboard at the same time on console via the kbdmux(4) driver, use the following sequence of commands.
kbdcontrol -K < /dev/console kbdcontrol -a atkbd0 < /dev/kbdmux0 kbdcontrol -a ukbd1 < /dev/kbdmux0 kbdcontrol -k /dev/kbdmux0 < /dev/console
kbdmap(1), vidcontrol(1), atkbd(4), kbdmux(4), keyboard(4), screen(4), syscons(4), ukbd(4), vt(4), kbdmap(5), rc.conf(5)
Søren Schmidt <sos@FreeBSD.org>
Report when found.
March 16, 2016 | midnightbsd-3.1 |