xref: /freebsd/usr.sbin/kbdcontrol/kbdcontrol.1 (revision 6ef10a4400cbf0391dcf8f355eb8750bb4336367)
1.\"
2.\" kbdcontrol - a utility for manipulating the syscons keyboard driver section
3.\"
4.\" Redistribution and use in source and binary forms, with or without
5.\" modification, are permitted provided that the following conditions
6.\" are met:
7.\" 1. Redistributions of source code must retain the above copyright
8.\"    notice, this list of conditions and the following disclaimer.
9.\" 2. Redistributions in binary form must reproduce the above copyright
10.\"    notice, this list of conditions and the following disclaimer in the
11.\"    documentation and/or other materials provided with the distribution.
12.\"
13.\"     @(#)kbdcontrol.1
14.\" $FreeBSD$
15.\"
16.Dd June 30, 1999
17.Dt KBDCONTROL 1
18.Os FreeBSD
19.Sh NAME
20.Nm kbdcontrol
21.Nd a utility for manipulating the syscons console driver
22.Sh SYNOPSIS
23.Nm
24.Op Fl dFKix
25.Op Fl b Ar duration.pitch | Ar belltype
26.Op Fl r Ar delay.repeat | Ar speed
27.Op Fl l Ar keymap_file
28.Op Fl f Ar # Ar string
29.Op Fl h Ar size
30.Op Fl k Ar keyboard_device
31.Op Fl L Ar keymap_file
32.Sh DESCRIPTION
33The
34.Nm
35command is used to set various keyboard related options for the
36.Xr syscons 4
37console driver and the keyboard drivers,
38such as key map, keyboard repeat and delay rates, bell
39characteristics etc.
40.Pp
41Keyboard options may be automatically configured at system boot time by
42setting variables in
43.Pa /etc/rc.conf .
44See
45.Sx Boot Time Configuration
46below.
47.Pp
48The following command line options are supported:
49.Bl -tag -width indent
50.It Fl b Ar duration.pitch | Ar belltype
51Set the bell duration in milliseconds and pitch in hertz.
52If a
53.Ar belltype
54argument is specified, it may be one of
55.Cm normal
56which sets sound parameters back to normal values,
57.Cm off
58which disables the bell entirely, or
59.Cm visual
60which sets the bell to visual mode, i.e. flashes the screen instead.
61If
62.Ar belltype
63is preceded by the word
64.Cm quiet. ,
65the bell will not be rung when the ringing process is in the background vty.
66.It Fl r Ar delay.repeat | Ar speed
67Set keyboard
68.Ar delay (250, 500, 750, 1000)
69and
70.Ar repeat (34, 38, 42, 46, 50, 55, 59, 63, 68, 76, 84, 92, 100, 110, 118, 126,
71136, 152, 168, 184, 200, 220, 236, 252, 272, 304, 336, 368, 400, 440,
72472, 504)
73rates, or if a
74.Ar speed
75argument is specified, it may be one of
76.Cm slow
77(1000.504),
78.Cm fast
79(250.34)
80or
81.Cm normal
82(500.126).
83.It Fl l Ar keymap_file
84Install keyboard map file from
85.Ar keymap_file .
86You may load the keyboard map file from a menu-driven command,
87.Xr kbdmap 1 .
88.It Fl d
89Dump the current keyboard map onto stdout.
90The output may be redirected to a file and can be loaded
91back to the kernel later by the
92.Fl l
93option above.
94.It Fl f Ar # Ar string
95Set function key number
96.Ar #
97to send
98.Ar string .
99Refer to the man page for the keyboard driver
100.Pq e.g. Xr atkbd 4
101for available function keys and their numbers.
102.It Fl F
103Set function keys back to the standard definitions.
104.It Fl x
105Use hexadecimal numbers in keyboard map dump.
106.It Fl h Ar size
107Set history buffer size to
108.Ar size
109lines.
110.It Fl i
111Print brief information about the keyboard.
112.It Fl K
113Disconnect the keyboard from the console.
114You need to use the
115.Fl k
116option below to associate a keyboard with the console again.
117.It Fl k Ar keyboard_device
118Use the specified device as the console keyboard.
119.It Fl L Ar keymap_file
120Load keyboard map file from
121.Ar keymap_file
122and write the
123.Ft "struct keymap"
124compiled from it to stdout.
125This option is primarily intended for programmers and is probably
126of little use under normal circumstances.
127.El
128.Sh KEYBOARD CONFIGURATION
129.Ss Boot Time Configuration
130You may set variables in
131.Pa /etc/rc.conf
132or
133.Pa /etc/rc.conf.local
134in order to configure the keyboard at boot time.
135The following is the list of relevant variables.
136.Pp
137.Bl -tag -width foo_bar_var -compact
138.It Ar keymap
139Specifies a keyboard map file for the
140.Fl l
141option.
142.It Ar keyrate
143Sets the keyboard repeat rate for the
144.Fl r
145option.
146.It Ar keychange
147Lists function key strings for the
148.Fl f
149option.
150.El
151.Pp
152See
153.Xr rc.conf 5
154for details.
155.Ss Driver Configuration
156The keyboard device driver may let you change default configuration
157options, such as the default keyboard map, so that you do not need to set up
158the options at boot time.
159See keyboard driver manuals
160.Pq e.g. Xr atkbd 4 , Xr ukbd 4
161for details.
162.Sh FILES
163.Bl -tag -width /usr/share/syscons/keymaps/foo_bar -compact
164.It Pa /usr/share/syscons/keymaps/*
165keyboard map files.
166.Sh EXAMPLE
167The following command will load the keyboard map file
168.Pa /usr/share/syscons/keymaps/ru.koi8-r.kbd .
169.Pp
170.Dl kbdcontrol -l /usr/share/syscons/keymaps/ru.koi8-r.kbd
171.Pp
172So long as the keyboard map file resides in
173.Pa /usr/share/syscons/keymaps ,
174you may abbreviate the file name as
175.Pa ru.koi8-r .
176.Pp
177.Dl kbdcontrol -l ru.koi8-r
178.Pp
179The following command will make the function key 10 emit "telnet myhost".
180.Pp
181.Dl kbdcontrol -f 10 \&"telnet myhost\&"
182.Pp
183In order to get the visual effect for bell, but prevent the screen
184from flushing if the bell is to ring in the background screen,
185run the following command.
186.Pp
187.Dl kbdcontrol -b quiet.visual
188.Pp
189.Sh BUGS
190Report when found.
191.Sh SEE ALSO
192.Xr kbdmap 1 ,
193.Xr vidcontrol 1 ,
194.Xr atkbd 4 ,
195.Xr keyboard 4 ,
196.Xr screen 4 ,
197.Xr syscons 4 ,
198.Xr ukbd 4 ,
199.Xr rc.conf 5 .
200.Sh AUTHORS
201.An S�ren Schmidt Aq sos@FreeBSD.org
202