summaryrefslogtreecommitdiff
path: root/doc/keys.txt
diff options
context:
space:
mode:
authorBenji Dial <benji6283@gmail.com>2020-09-13 03:19:57 -0400
committerBenji Dial <benji6283@gmail.com>2020-09-13 03:19:57 -0400
commit1e4a254674f668839e5de273916024c16814b045 (patch)
tree6774f4d4398a29c4aafb4120070975d864ffcde4 /doc/keys.txt
parentb8284137d4e0eec11c78bc14047243fce6a51373 (diff)
downloadportland-os-1e4a254674f668839e5de273916024c16814b045.tar.gz
(basic, not much tested) keyboard, better panic
Diffstat (limited to 'doc/keys.txt')
-rw-r--r--doc/keys.txt73
1 files changed, 68 insertions, 5 deletions
diff --git a/doc/keys.txt b/doc/keys.txt
index a083eba..8deb480 100644
--- a/doc/keys.txt
+++ b/doc/keys.txt
@@ -2,7 +2,7 @@ keycodes are 32-bit integers.
the low byte indicates the key itself. for printable characters (and keys with
reasonable translations to ascii control codes), this is the ascii code. for
-other ones, something in the range of 0x80 to 0xff is used, seen in table 1.
+other ones, something in the range of 0x80 to 0xef is used, seen in table 1.
the top 24 bits indicate several flags. these are seen in table 2, where bit 0
is the lowest bit of the second lowest byte of the keycode, and bit 23 is the
@@ -18,10 +18,73 @@ user.c of the "knob" library for an example of this.
table 1:
code | key
-------|-----
- 0x80 |
- .... |
- 0xff |
+------|---------------
+ 0x80 | caps lock
+ 0x81 | insert
+ 0x82 | num lock
+ 0x83 | scroll lock
+ 0x84 | left shift
+ 0x85 | right shift
+ 0x86 | left alt
+ 0x87 | right alt
+ 0x88 | left control
+ 0x89 | right control
+ 0x8a | left meta
+ 0x8b | right meta
+ 0x8c | reserved
+ .... | reserved
+ 0x97 | reserved
+ 0x98 | unassigned
+ .... | unassigned
+ 0x9f | unassigned
+ 0xa0 | F1
+ 0xa1 | F2
+ 0xa2 | F3
+ 0xa3 | F4
+ 0xa4 | F5
+ 0xa5 | F6
+ 0xa6 | F7
+ 0xa7 | F8
+ 0xa8 | F9
+ 0xa9 | F10
+ 0xaa | F11
+ 0xab | F12
+ 0xac | unassigned
+ .... | unassigned
+ 0xaf | unassigned
+ 0xb0 | numpad 0
+ 0xb1 | numpad 1
+ 0xb2 | numpad 2
+ 0xb3 | numpad 3
+ 0xb4 | numpad 4
+ 0xb5 | numpad 5
+ 0xb6 | numpad 6
+ 0xb7 | numpad 7
+ 0xb8 | numpad 8
+ 0xb9 | numpad 9
+ 0xba | numpad *
+ 0xbb | numpad +
+ 0xbc | numpad Enter
+ 0xbd | numpad -
+ 0xbe | numpad .
+ 0xbf | numpad /
+ 0xc0 | unassigned
+ 0xc1 | delete
+ 0xc2 | home
+ 0xc3 | end
+ 0xc4 | page up
+ 0xc5 | page down
+ 0xc6 | up
+ 0xc7 | down
+ 0xc8 | left
+ 0xc9 | right
+ 0xca | escape
+ 0xcb | menu
+ 0xcc | pause
+ 0xcd | print screen
+ 0xce | unassigned
+ .... | unassigned
+ 0xef | unassigned
table 2: