NetBSD-Bugs archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: bin/49998: wsconsctl does not modify keyboard encoding correctly
The following reply was made to PR bin/49998; it has been noted by GNATS.
From: Vicente Chaves de Melo <vchaves%ymail.com@localhost>
To: gnats-bugs%NetBSD.org@localhost
Cc:
Subject: Re: bin/49998: wsconsctl does not modify keyboard encoding correctly
Date: Mon, 27 Jul 2015 17:37:07 -0300
Hello
Finally I was able to understand the source of the problem and create a
workaround to allow the correct operation of the abnt2 usb keyboard.
In this particular server there is only a USB keyboard connected, but
due to the BIOS setup the kernel identifies two keyboard during the
boot, a pckbd0 and other ukbd0 as we can see below:
target# dmesg | grep wskbd
wskbd0 at pckbd0: console keyboard, using wsdisplay0
wskbd1 at ukbd0 mux 1
wskbd1: connecting to wsdisplay0
target# wsmuxctl -f /dev/wsmux1 -L
wskbd0
wskbd1
When I run the command wsconsctl -w map+="keycode 20 = q Q slash" the
kernel gets confused and changes the maplen of ukbd0 (sc_maplen=232) to
be equal to that of pckbd0(sc_maplen=222), which effectively removes
from ukbd0 device, keys with keycode greater than 222:
keycode 224 = Cmd1 Control_L
keycode 225 = Shift_L
keycode 226 = Cmd2 Alt_L
keycode 227 = Meta_L
keycode 228 = Control_R
keycode 229 = Shift_R
keycode 230 = Mode_switch Multi_key
keycode 231 = Meta_R
What makes the keyboard useless.
I created the file /usr/share/wscons/keymaps/ukbd.br.abnt2 to be used to
map the usb keyboard ABNT2 that explicitly adds the keys with encoding
greater than 222:
target# cat /usr/share/wscons/keymaps/ukbd.br.abnt2
keycode 30 = 1 exclam onesuperior
keycode 31 = 2 at twosuperior
keycode 32 = 3 numbersign threesuperior
keycode 33 = 4 dollar sterling
keycode 34 = 5 percent cent
keycode 35 = 6 dead_diaeresis notsign
keycode 46 = equal plus section
keycode 20 = q Q slash
keycode 26 = w W question
keycode 8 = e E degree
keycode 47 = dead_acute dead_grave
keycode 48 = bracketleft braceleft ordfeminine
keycode 51 = ccedilla Ccedilla
keycode 52 = dead_tilde dead_circumflex
keycode 53 = apostrophe quotedbl
keycode 49 = bracketright braceright masculine
keycode 56 = semicolon colon
keycode 50 = backslash bar
keycode 99 = KP_Delete KP_Separator
keycode 135 = slash question degree
keycode 133 = KP_Decimal
keycode 224 = Cmd1 Control_L
keycode 225 = Shift_L
keycode 226 = Cmd2 Alt_L
keycode 227 = Meta_L
keycode 228 = Control_R
keycode 229 = Shift_R
keycode 230 = Mode_switch Multi_key
keycode 231 = Meta_R
I can confirm that with this file I have a fully functional USB
Brazilian ABNT2 keyboard.
It would be nice if this file is made available for use by another
Brazilian users
From my point of view this PR can be closed
Best regards
Vicente
On 23/06/2015 14:30, gnats-admin%netbsd.org@localhost wrote:
> Thank you very much for your problem report.
> It has the internal identification `bin/49998'.
> The individual assigned to look at your
> report is: bin-bug-people.
>
>> Category: bin
>> Responsible: bin-bug-people
>> Synopsis: wsconsctl does not modify keyboard encoding correctly
>> Arrival-Date: Tue Jun 23 17:30:00 +0000 2015
Home |
Main Index |
Thread Index |
Old Index