I don't think KEYB SP is working right...
I don't think KEYB SP is working right...
I regularly use several DOS machines, and I just realised the symbols no longer match my keyboard's, despite having loaded KEYB SP. I don't think i had this issue with v14, but I'm not sure. Can anyone reproduce this?
Last edited by Neville on Wed 05 Jun, 2019 6:55 pm, edited 1 time in total.
Re: I don't think KEYB SP is working right...
MS-DOS 6.22 here and all fine ( normal, shift and alt+gr characters)
config.sys:
COUNTRY=034,,C:\DOS\COUNTRY.SYS
DEVICEHIGH=C:\DOS\DISPLAY.SYS CON=(EGA,,1)
autoexec.bat
MODE CON CODEPAGE PREPARE=((850) C:\DOS\EGA.CPI)
MODE CON CODEPAGE SELECT=850
KEYB SP,,C:\DOS\KEYBOARD.SYS
config.sys:
COUNTRY=034,,C:\DOS\COUNTRY.SYS
DEVICEHIGH=C:\DOS\DISPLAY.SYS CON=(EGA,,1)
autoexec.bat
MODE CON CODEPAGE PREPARE=((850) C:\DOS\EGA.CPI)
MODE CON CODEPAGE SELECT=850
KEYB SP,,C:\DOS\KEYBOARD.SYS
Re: I don't think KEYB SP is working right...
I'm just loading KEYB SP at the end of my AUTOEXEC.BAT, but that used to suffice on the old days.
- ruben_balea
- Posts: 104
- Joined: Mon 08 May, 2017 11:24 pm
- Location: Spain
Re: I don't think KEYB SP is working right...
No, it doesn't work correctly. Until now I thought it was fine because on Windows it was working fine... until I launched a MS-DOS session
On Windows ME the keyboard is fine for Windows programs but for DOS programs it doesn't work.
Note: KEYB command is no longer available on Windows ME, the keyboard layout for legacy DOS programs is set automatically according to the keyboard language selected for Windows.
I typed the same keys in the same order on Notepad and MS-DOS Editor, some keys give different results and ALT-GR characters are not showing at all on DOS:
And this happens also on another machine with MS-DOS 6.2x using KEYB SP but the same hard disk image (with same settings, no modifications at all) works OK on V14

On Windows ME the keyboard is fine for Windows programs but for DOS programs it doesn't work.
Note: KEYB command is no longer available on Windows ME, the keyboard layout for legacy DOS programs is set automatically according to the keyboard language selected for Windows.
I typed the same keys in the same order on Notepad and MS-DOS Editor, some keys give different results and ALT-GR characters are not showing at all on DOS:
And this happens also on another machine with MS-DOS 6.2x using KEYB SP but the same hard disk image (with same settings, no modifications at all) works OK on V14
Re: I don't think KEYB SP is working right...
Thank you. For a moment I thought I was seeing ghosts.
- ruben_balea
- Posts: 104
- Joined: Mon 08 May, 2017 11:24 pm
- Location: Spain
Re: I don't think KEYB SP is working right...
I'm quite used to hte US keyboard layout, you can download a picture of that keyboard to see what key you have to press for each symbol when a KEYB command or similar is not available or not working.
Please note that the backslash key located above ENTER in the US layout is placed between Left SHIFT and Z on most other layouts, also the right Alt is replaced with Alt Gr.
Also remember that if you already used KEYB xx (manually or from autoexec.bat) and it's not working properly you must run KEYB US again, otherwise you'll end with a big mess of layouts.
Wikipedia has this picture of the IBM Model M keyboard with US layout:

Please note that the backslash key located above ENTER in the US layout is placed between Left SHIFT and Z on most other layouts, also the right Alt is replaced with Alt Gr.
Also remember that if you already used KEYB xx (manually or from autoexec.bat) and it's not working properly you must run KEYB US again, otherwise you'll end with a big mess of layouts.
Wikipedia has this picture of the IBM Model M keyboard with US layout:

Re: I don't think KEYB SP is working right...
Thanks for the tip.
Re: I don't think KEYB SP is working right...
MS DOS 6.22 -> Fine
Command prompt on Windows 98 -> Fine
PCem V15 Command prompt on Windows Me -> Error as in ruben's post.
PCem V14 Command prompt on Windows Me -> Works ( same disk image and config as above)
Command prompt on Windows 98 -> Fine
PCem V15 Command prompt on Windows Me -> Error as in ruben's post.
PCem V14 Command prompt on Windows Me -> Works ( same disk image and config as above)
Re: I don't think KEYB SP is working right...
I'm getting wrong results under MS-DOS 6.22. This is what I get when I press Mays + the top row in my keyboard, under the function keys:


- ruben_balea
- Posts: 104
- Joined: Mon 08 May, 2017 11:24 pm
- Location: Spain
Re: I don't think KEYB SP is working right...
For me MS-DOS 6.22 is wrong too:
Edit: I compiled PCem five weeks ago, I will update it now and test again.
Edit 2: Only 'makefile.in' was changed since last update…
Edit 3: KEYB UK is not working 100% properly either.
Edit: I compiled PCem five weeks ago, I will update it now and test again.
Edit 2: Only 'makefile.in' was changed since last update…
Edit 3: KEYB UK is not working 100% properly either.
Last edited by ruben_balea on Tue 25 Jun, 2019 12:44 am, edited 1 time in total.
- ruben_balea
- Posts: 104
- Joined: Mon 08 May, 2017 11:24 pm
- Location: Spain
Re: I don't think KEYB SP is working right...

With KEYB UK the key at the left of '1' works as a duplicate of the key at the left of 'Z'

This is the result of the full numbers row with and witouth pressing also the 'SHIFT' key:
Re: I don't think KEYB SP is working right...
I am unsure why you have the problem on MS-DOS, since it works here, but since I had the problem in WinMe, I tried recompiling the sources and located the commit 1432 "Add ability to change AT keyboard scancode and disable translation. Fixes keyboard in Solaris 8." to cause the command prompt on WinMe to fail on my side.
- ruben_balea
- Posts: 104
- Joined: Mon 08 May, 2017 11:24 pm
- Location: Spain
Re: I don't think KEYB SP is working right...
OK, I seen the updates to 'keyboard_ac.c' so I did a few more tests, KEYB SP with a PS/2 keyboard works in MS-DOS 6.22, with a XT keyboard works too but with an AT keyboard does not work.
The same applies for KEYB UK but on this case seems to be wrong only the key at the left of '1' which types the same characters as the key at the left of 'Z' i.e., \|
Note: With each kind of keyboard I mean emulating a motherboard with that kind of keyboard, not to the physical keyboard I'm using.
The same applies for KEYB UK but on this case seems to be wrong only the key at the left of '1' which types the same characters as the key at the left of 'Z' i.e., \|
Note: With each kind of keyboard I mean emulating a motherboard with that kind of keyboard, not to the physical keyboard I'm using.
Re: I don't think KEYB SP is working right...
Same for "german" keyb layout... Does not work with a dos version below 6.22.... Keyboard "freezes" when pressing [ALT GR]... So no Backslash possible with german keyboard driver
Re: I don't think KEYB SP is working right...
i can emulate the backslash with <STRG> + <ALT> + <#> on an IBM Thinkpad T440p with native German Keyboard running Windows 10 (German)