Path: utzoo!attcan!uunet!lll-winken!ncis!helios.ee.lbl.gov!pasteur!ucbvax!decwrl!purdue!mailrus!tut.cis.ohio-state.edu!rutgers!ukma!psuvm.bitnet!bp3 From: BP3@PSUVM.BITNET (Larry Belan) Newsgroups: comp.sys.ibm.pc Subject: Re: Enhanced Keyboard Scan Codes Message-ID: <68082BP3@PSUVM> Date: 19 Jan 89 14:43:14 GMT Organization: Penn State University - Center for Academic Computing Lines: 96 Since Mitch was unable to post this...I will do it for him. Received: from CORNELLA.BITNET by PSUVM.BITNET (Mailer X1.25) with BSMTP id 7758; Wed, 18 Jan 89 15:35:19 EST Received: by CORNELLA (Mailer R2.01) id 6621; Wed, 18 Jan 89 15:37:46 EST Date: Wed, 18 Jan 89 15:31:46 EST From: Rich Kennerly Subject: enhanced keyboards To: Larry Belan cc: Mitchell S Gorman Larry, Mitch, Here is a list of the extra keys on an enhanced keyboard: Enhanced Keyboard key: BIOS value: base shift cntrl alt F11 8500 8700 8900 8b00 F12 8600 8800 8A00 8C00 kp-Enter E00D E00D E00D A600 KP-/ E02F E02F 9500 A400 KP-* 372A 372A 9600 3700 HOME 47E0 47E0 77E0 9700 UP ARROW 48E0 48E0 8DE0 9800 PAGE UP 49E0 49E0 84E0 9900 LEFT ARROW 4BE0 4BE0 73E0 9B00 RIGHT ARROW 4DE0 4DE0 74E0 9D00 END 4FE0 4FE0 75E0 9F00 DOWN ARROW 50E0 50E0 91E0 A000 PAGE DOWN 51E0 51E0 76E0 A100 INSERT 52E0 52E0 92E0 A200 DELETE 53E0 53E0 93E0 A300 Note that you cannot get these values with the old BIOS interrupt, it will remove the E0's to be compatible with the old keyboard. See the following code fragments that use the old and new BIOS calls. getkey_ PROC NEAR ; get key code for standard keyboard mov ah,01H int 16h jnz GOTAKEY mov ax,00H ret GOTAKEY: mov ah,00H int 16h ret getkey_ ENDP getxkey_ PROC NEAR ; get key code for enhanced keyboard mov ah,11H int 16h jnz GOTXKEY mov ax,0 ret GOTXKEY: mov ah,10H int 16h ret getxkey_ ENDP I have found that an AT with old keyboard and old BIOS (you need the new BIOS to fully appreciate the enhanced keyboard) will get very upset if you try to use the new BIOS function calls with it. Here is a routine that will look into the BIOS data area to see if BIOS found an enhanced keyboard at INIT time. Note that this approach is not ideal since IBM and others can change the layout of BIOS at will; fortunately they never seem to. In any case there is no interrupt call that will tell you this (if there is let me know please). ; gkybdtype returns 0 for standard 84 key kybd, 10H for enhanced keyboard KB_FLAG_3 equ 096H ; address of keyboard flag byte KBX equ 00010000B ; enhanced keyboard flag bit gkybdtype_ proc near push es mov ax,40H mov es, ax mov ax,es:[KB_FLAG_3] and ax,KBX pop es ret gkybdtype_ endp Do either of you know the userid/node that I should send letters for this newsgroup (ibm.pc)? Our local machine does not forward to the entire net. If not feel free to forward this. RICH KENNERLY - LVL@CORNELLA.CIT.CORNELL.EDU CIT - Network Development 125 Caldwell Hall 607-255-7342