| @@ -1,40 +1,40 @@ | | | @@ -1,40 +1,40 @@ |
1 | .\" $NetBSD: wskbd.4,v 1.17 2019/08/12 11:11:28 nia Exp $ | | 1 | .\" $NetBSD: wskbd.4,v 1.18 2020/07/13 11:14:12 nia Exp $ |
2 | .\" | | 2 | .\" |
3 | .\" Copyright (c) 1999 | | 3 | .\" Copyright (c) 1999 |
4 | .\" Matthias Drochner. All rights reserved. | | 4 | .\" Matthias Drochner. All rights reserved. |
5 | .\" | | 5 | .\" |
6 | .\" Redistribution and use in source and binary forms, with or without | | 6 | .\" Redistribution and use in source and binary forms, with or without |
7 | .\" modification, are permitted provided that the following conditions | | 7 | .\" modification, are permitted provided that the following conditions |
8 | .\" are met: | | 8 | .\" are met: |
9 | .\" 1. Redistributions of source code must retain the above copyright | | 9 | .\" 1. Redistributions of source code must retain the above copyright |
10 | .\" notice, this list of conditions and the following disclaimer. | | 10 | .\" notice, this list of conditions and the following disclaimer. |
11 | .\" 2. Redistributions in binary form must reproduce the above copyright | | 11 | .\" 2. Redistributions in binary form must reproduce the above copyright |
12 | .\" notice, this list of conditions and the following disclaimer in the | | 12 | .\" notice, this list of conditions and the following disclaimer in the |
13 | .\" documentation and/or other materials provided with the distribution. | | 13 | .\" documentation and/or other materials provided with the distribution. |
14 | .\" | | 14 | .\" |
15 | .\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND | | 15 | .\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND |
16 | .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE | | 16 | .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE |
17 | .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE | | 17 | .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE |
18 | .\" ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE | | 18 | .\" ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE |
19 | .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL | | 19 | .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL |
20 | .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS | | 20 | .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS |
21 | .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) | | 21 | .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) |
22 | .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT | | 22 | .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT |
23 | .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY | | 23 | .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY |
24 | .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF | | 24 | .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF |
25 | .\" SUCH DAMAGE. | | 25 | .\" SUCH DAMAGE. |
26 | .\" | | 26 | .\" |
27 | .Dd May 27, 2012 | | 27 | .Dd July 13, 2020 |
28 | .Dt WSKBD 4 | | 28 | .Dt WSKBD 4 |
29 | .Os | | 29 | .Os |
30 | .Sh NAME | | 30 | .Sh NAME |
31 | .Nm wskbd | | 31 | .Nm wskbd |
32 | .Nd generic keyboard support in wscons | | 32 | .Nd generic keyboard support in wscons |
33 | .Sh SYNOPSIS | | 33 | .Sh SYNOPSIS |
34 | .Cd "wskbd* at pckbd? console ? mux 1" | | 34 | .Cd "wskbd* at pckbd? console ? mux 1" |
35 | (standard PC keyboard) | | 35 | (standard PC keyboard) |
36 | .Cd "wskbd* at ukbd? console ? mux 1" | | 36 | .Cd "wskbd* at ukbd? console ? mux 1" |
37 | (USB keyboard) | | 37 | (USB keyboard) |
38 | .Cd "wskbd* at lkkbd? console ? mux 1" | | 38 | .Cd "wskbd* at lkkbd? console ? mux 1" |
39 | (DEC LK200/400 serial keyboard) | | 39 | (DEC LK200/400 serial keyboard) |
40 | .Cd "wskbd0 at akbd? console ? mux 1" | | 40 | .Cd "wskbd0 at akbd? console ? mux 1" |
| @@ -104,26 +104,107 @@ A complete list is in | | | @@ -104,26 +104,107 @@ A complete list is in |
104 | The | | 104 | The |
105 | .Xr wsconsctl 8 | | 105 | .Xr wsconsctl 8 |
106 | utility allows to access key maps and other variables. | | 106 | utility allows to access key maps and other variables. |
107 | .Pp | | 107 | .Pp |
108 | The | | 108 | The |
109 | .Em console | | 109 | .Em console |
110 | locator in the configuration line refers to the device's use as input | | 110 | locator in the configuration line refers to the device's use as input |
111 | part of the operating system console. | | 111 | part of the operating system console. |
112 | A device specification containing a positive value here will only | | 112 | A device specification containing a positive value here will only |
113 | match if the device is in use as system console. | | 113 | match if the device is in use as system console. |
114 | (The console device selection in early system startup is not influenced.) | | 114 | (The console device selection in early system startup is not influenced.) |
115 | This way, the console device can be connected to a known | | 115 | This way, the console device can be connected to a known |
116 | wskbd device instance. | | 116 | wskbd device instance. |
| | | 117 | .Ss Keyboard encodings |
| | | 118 | The following encodings are supported. |
| | | 119 | Device drivers for legacy keyboard interfaces may only support a subset |
| | | 120 | of these. |
| | | 121 | However, generally, all encodings are supported by |
| | | 122 | .Xr pckbd 4 and |
| | | 123 | .Xr ukbd 4 . |
| | | 124 | .Bl -column " us.colemak" " KB_US|KB_COLEMAK" "language" |
| | | 125 | .It Sy "wsconsctl" Ta Sy "define" Ta Sy "language" |
| | | 126 | .It Li user Ta KB_USER Ta User-defined |
| | | 127 | .It Li us Ta KB_US Ta English/US keyboard mapping (default) |
| | | 128 | .It Li uk Ta KB_UK Ta English/UK keyboard mapping |
| | | 129 | .It Li be Ta KB_BE Ta Belgian |
| | | 130 | .It Li br Ta KB_BR Ta Brazilian with |
| | | 131 | .Dq dead accents |
| | | 132 | .It Li cf Ta KB_CF Ta Canadian French |
| | | 133 | .It Li cz Ta KB_CZ Ta Czech (QWERTY) |
| | | 134 | .It Li dk Ta KB_DK Ta Danish with |
| | | 135 | .Dq dead accents |
| | | 136 | .It Li nl Ta KB_NL Ta Dutch |
| | | 137 | .It Li ee Ta KB_DK Ta Estonian with |
| | | 138 | .Dq dead accents |
| | | 139 | .It Li fi Ta KB_FI Ta Finnish |
| | | 140 | .It Li fr Ta KB_FR Ta French |
| | | 141 | .It Li de Ta KB_DE Ta German with |
| | | 142 | .Dq dead accents |
| | | 143 | .It Li gr Ta KB_GR Ta Greek |
| | | 144 | .It Li hu Ta KB_HU Ta Hungarian |
| | | 145 | .It Li is Ta KB_IS Ta Icelandic with |
| | | 146 | .Dq dead accents |
| | | 147 | .It Li it Ta KB_IT Ta Italian |
| | | 148 | .It Li jp Ta KB_JP Ta Japanese |
| | | 149 | .It Li no Ta KB_NO Ta Norwegian with |
| | | 150 | .Dq dead accents |
| | | 151 | .It Li pl Ta KB_PL Ta Polish |
| | | 152 | .It Li pt Ta KB_PT Ta Portuguese |
| | | 153 | .It Li ru Ta KB_RU Ta Russian |
| | | 154 | .It Li es Ta KB_ES Ta Spanish |
| | | 155 | .It Li sv Ta KB_SV Ta Swedish with |
| | | 156 | .Dq dead accents |
| | | 157 | .It Li sf Ta KB_SF Ta Swiss French |
| | | 158 | .It Li sg Ta KB_SG Ta Swiss German |
| | | 159 | .It Li tr Ta KB_TR Ta Turkish (QWERTY) with |
| | | 160 | .Dq dead accents |
| | | 161 | .It Li ua Ta KB_UA Ta Ukrainian |
| | | 162 | .It Li \&us.declk Ta "KB_US|KB_DECLK" Ta English/US mapping for Tn DEC |
| | | 163 | .It Ta Ta LK400-style keyboards with PC keyboard |
| | | 164 | .It Ta Ta interface (e.g., LK461) |
| | | 165 | .It Li us.dvorak Ta "KB_US|KB_DVORAK" Ta English/US keyboard with |
| | | 166 | .It Ta Ta Do Dvorak Dc layout |
| | | 167 | .It Li us.colemak Ta "KB_US|KB_COLEMAK" Ta English/US keyboard with |
| | | 168 | .It Ta Ta Do Colemak Dc layout |
| | | 169 | .El |
| | | 170 | .Pp |
| | | 171 | .Li KB_NODEAD ( |
| | | 172 | .Dq .nodead ) |
| | | 173 | can be applied to layouts with |
| | | 174 | .Dq dead accents |
| | | 175 | to switch them off. |
| | | 176 | .Pp |
| | | 177 | The |
| | | 178 | .Li KB_US , |
| | | 179 | .Li KB_UK , |
| | | 180 | .Li KB_FR , |
| | | 181 | .Li KB_JP |
| | | 182 | and |
| | | 183 | .Li KB_US|KB_DVORAK |
| | | 184 | mappings can be modified |
| | | 185 | to swap the left CTRL and the CAPS LOCK keys by the |
| | | 186 | .Li KB_SWAPCTRLCAPS |
| | | 187 | variant bit or the |
| | | 188 | .Dq .swapctrlcaps |
| | | 189 | suffix. |
| | | 190 | .Pp |
| | | 191 | The |
| | | 192 | .Li KB_METAESC ( |
| | | 193 | .Dq .metaesc ) |
| | | 194 | option can be applied to any layout. |
| | | 195 | If set, keys pressed together |
| | | 196 | with the ALT modifier are prefixed by an ESC character. |
| | | 197 | (Standard behaviour is to add 128 to the ASCII value.) |
117 | .Ss Ioctls | | 198 | .Ss Ioctls |
118 | The following | | 199 | The following |
119 | .Xr ioctl 2 | | 200 | .Xr ioctl 2 |
120 | calls are provided by the | | 201 | calls are provided by the |
121 | .Nm | | 202 | .Nm |
122 | driver or by devices which use it. | | 203 | driver or by devices which use it. |
123 | Their definitions are found in | | 204 | Their definitions are found in |
124 | .Pa dev/wscons/wsconsio.h . | | 205 | .Pa dev/wscons/wsconsio.h . |
125 | .Bl -tag -width Dv | | 206 | .Bl -tag -width Dv |
126 | .It Dv WSKBDIO_GTYPE | | 207 | .It Dv WSKBDIO_GTYPE |
127 | Get the keyboard type. | | 208 | Get the keyboard type. |
128 | .It Dv WSKBDIO_COMPLEXBELL, WSKBDIO_SETBELL, WSKBDIO_GETBELL, WSKBDIO_SETDEFAULTBELL, WSKBDIO_GETDEFAULTBELL Pq Li "struct wsmouse_repeat" | | 209 | .It Dv WSKBDIO_COMPLEXBELL, WSKBDIO_SETBELL, WSKBDIO_GETBELL, WSKBDIO_SETDEFAULTBELL, WSKBDIO_GETDEFAULTBELL Pq Li "struct wsmouse_repeat" |
129 | Get and set keyboard bell settings. | | 210 | Get and set keyboard bell settings. |
| @@ -159,13 +240,16 @@ if (ioctl(fd, WSKBDIO_SETVERSION, &ver) | | | @@ -159,13 +240,16 @@ if (ioctl(fd, WSKBDIO_SETVERSION, &ver) |
159 | .It | | 240 | .It |
160 | .Pa /usr/include/dev/wscons/wsksymdef.h | | 241 | .Pa /usr/include/dev/wscons/wsksymdef.h |
161 | .It | | 242 | .It |
162 | .Pa /usr/include/dev/wscons/wsconsio.h . | | 243 | .Pa /usr/include/dev/wscons/wsconsio.h . |
163 | .El | | 244 | .El |
164 | .Sh SEE ALSO | | 245 | .Sh SEE ALSO |
165 | .Xr btkbd 4 , | | 246 | .Xr btkbd 4 , |
166 | .Xr pckbd 4 , | | 247 | .Xr pckbd 4 , |
167 | .Xr ukbd 4 , | | 248 | .Xr ukbd 4 , |
168 | .Xr wscons 4 , | | 249 | .Xr wscons 4 , |
169 | .Xr wsmux 4 , | | 250 | .Xr wsmux 4 , |
170 | .Xr wsconsctl 8 , | | 251 | .Xr wsconsctl 8 , |
171 | .Xr wskbd 9 | | 252 | .Xr wskbd 9 |
| | | 253 | .Sh BUGS |
| | | 254 | The list of builtin mappings doesn't follow any logic. |
| | | 255 | It grew as people submitted what they needed. |