Deleted Added
full compact
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: head/usr.sbin/kbdcontrol/kbdcontrol.1 65807 2000-09-13 09:16:57Z dwmalone $
14.\" $FreeBSD: head/usr.sbin/kbdcontrol/kbdcontrol.1 68717 2000-11-14 13:09:12Z ru $
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
69(250, 500, 750, 1000)
70and
71.Ar repeat
72(34, 38, 42, 46, 50, 55, 59, 63, 68, 76, 84, 92, 100, 110, 118, 126,
73136, 152, 168, 184, 200, 220, 236, 252, 272, 304, 336, 368, 400, 440,
74472, 504)
75rates, or if a
76.Ar speed
77argument is specified, it may be one of
78.Cm slow
79(1000.504),
80.Cm fast
81(250.34)
82or
83.Cm normal
84(500.126).
85.It Fl l Ar keymap_file
86Install keyboard map file from
87.Ar keymap_file .
88You may load the keyboard map file from a menu-driven command,
89.Xr kbdmap 1 .
90.It Fl d
91Dump the current keyboard map onto stdout.
92The output may be redirected to a file and can be loaded
93back to the kernel later by the
94.Fl l
95option above.
96.It Fl f Ar # Ar string
97Set function key number
98.Ar #
99to send
100.Ar string .
101Refer to the man page for the keyboard driver
102.Pq e.g. Xr atkbd 4
103for available function keys and their numbers.
104.It Fl F
105Set function keys back to the standard definitions.
106.It Fl x
107Use hexadecimal numbers in keyboard map dump.
108.It Fl h Ar size
109Set history buffer size to
110.Ar size
111lines.
112.It Fl i
113Print brief information about the keyboard.
114.It Fl K
115Disconnect the keyboard from the console.
116You need to use the
117.Fl k
118option below to associate a keyboard with the console again.
119.It Fl k Ar keyboard_device
120Use the specified device as the console keyboard.
121When using this option, the standard input of the
122.Nm
123process should be redirected from
124.Pa /dev/console
125if you are not working on the system console
126(see the
127.Sx EXAMPLES
128section).
129.It Fl L Ar keymap_file
130Load keyboard map file from
131.Ar keymap_file
132and write the
133.Ft "struct keymap"
134compiled from it to stdout.
135This option is primarily intended for programmers and is probably
136of little use under normal circumstances.
137.El
138.Sh KEYBOARD CONFIGURATION
139.Ss Boot Time Configuration
140You may set variables in
141.Pa /etc/rc.conf
142or
143.Pa /etc/rc.conf.local
144in order to configure the keyboard at boot time.
145The following is the list of relevant variables.
146.Pp
147.Bl -tag -width foo_bar_var -compact
148.It Ar keymap
149Specifies a keyboard map file for the
150.Fl l
151option.
152.It Ar keyrate
153Sets the keyboard repeat rate for the
154.Fl r
155option.
156.It Ar keychange
157Lists function key strings for the
158.Fl f
159option.
160.El
161.Pp
162See
163.Xr rc.conf 5
164for details.
165.Ss Driver Configuration
166The keyboard device driver may let you change default configuration
167options, such as the default keyboard map, so that you do not need to set up
168the options at boot time.
169See keyboard driver manuals
170.Pq e.g. Xr atkbd 4 , Xr ukbd 4
171for details.
172.Sh FILES
173.Bl -tag -width /usr/share/syscons/keymaps/foo_bar -compact
174.It Pa /usr/share/syscons/keymaps/*
175keyboard map files
176.Sh EXAMPLE
177The following command will load the keyboard map file
178.Pa /usr/share/syscons/keymaps/ru.koi8-r.kbd .
179.Pp
180.Dl kbdcontrol -l /usr/share/syscons/keymaps/ru.koi8-r.kbd
181.Pp
182So long as the keyboard map file resides in
183.Pa /usr/share/syscons/keymaps ,
184you may abbreviate the file name as
185.Pa ru.koi8-r .
186.Pp
187.Dl kbdcontrol -l ru.koi8-r
188.Pp
189The following command will make the function key 10 emit "telnet myhost".
190.Pp
191.Dl kbdcontrol -f 10 \&"telnet myhost\&"
192.Pp
193In order to get the visual effect for bell, but prevent the screen
194from flushing if the bell is to ring in the background screen,
195run the following command.
196.Pp
197.Dl kbdcontrol -b quiet.visual
198.Pp
199To change the default console keyboard to the another keyboard,
200for example the first USB keyboard (see
201.Xr ukbd 4 ) ,
202use the following commands.
203.Pp
204.Dl kbdcontrol -k /dev/kbd1 < /dev/console
205.Pp
206To switch back to the default keyboard, use this command.
207.Pp
208.Dl kbdcontrol -k /dev/kbd0
209.Pp
210.Sh BUGS
211Report when found.
212.Sh SEE ALSO
213.Xr kbdmap 1 ,
214.Xr vidcontrol 1 ,
215.Xr atkbd 4 ,
216.Xr keyboard 4 ,
217.Xr screen 4 ,
218.Xr syscons 4 ,
219.Xr ukbd 4 ,
220.Xr kbdmap 5 ,
221.Xr rc.conf 5
222.Sh AUTHORS
223.An Sren Schmidt Aq sos@FreeBSD.org
223.An S\(/oren Schmidt Aq sos@FreeBSD.org