Scancode

From BR Wiki
Revision as of 15:03, 28 July 2015 by Laura (talk | contribs)
Jump to navigation Jump to search

A scan code is a two-part or four-part hexadecimal code associated with a keystroke (so called because it comes from scanning the keyboard).

To determine the standardized Business Rules scancodes, run the following program:

10 LET X$ = KSTAT$(1)
20 PRINT UNHEX$(X$)
30 GOTO 10

Each time you press a key, the scancode for that key is displayed.

Here are a few of the Scan codes:

Key Scan Code
Tab 09
Shift+Tab 07
Down Arrow 0A
Up Arrow 0B
Left Arrow 0E
Right Arrow 0C
F7 0700
Shift+F7 1100
Alt+Down Arrow E300

Here's a complete list:

Key Shifted (IBM-PC) Kstat Shifted (qwerty) Control Description
Key Alt
a A 61 41 1E00 01 interrupt/break
b B 62 42 3000 02 page up (back)
c C 63 43 2E00 03 copy to clipboard
d D 64 44 2000 04 delete
e E 65 45 1200 05 end field
f F 66 46 2100 06 page down (forward)
g G 67 47 2200 07 backtab
h H 68 48 2300 08 backspace
i I 69 49 1700 09 tab
j J 6A 4A 2400 0A next field
k K 6B 4B 2500 0B prior field
l L 6C 4C 2600 0C right arrow
m M 6D 4D 3100 0D enter
n N 6E 4E 3200 0E left arrow
o O 6F 4F 1800 0F field minus
p P 70 50 1900 10 print screen
q Q 71 51 1000 11 toggle insert mode
r R 72 52 1300 12 up field (rise)
s S 73 53 1F00 13 togge hold mode (stop)
t T 74 54 1400 14 down field
u U 75 55 1600 15 field plus
v V 76 56 2F00 16 paste clipboard content
w W 77 57 1100 17 home
x X 78 58 2D00 18 cut to clipboard
y Y 79 59 1500 19 help
z Z 7A 5A 2C00 1A restore field contents


See the KStat$ internal function for more information.