Commit | Line | Data |
---|---|---|
b744cdaa CT |
1 | /* |
2 | * Copyright (c) 1992 The Regents of the University of California. | |
3 | * All rights reserved. | |
4 | * | |
5 | * This software was developed by the Computer Systems Engineering group | |
6 | * at Lawrence Berkeley Laboratory under DARPA contract BG 91-66 and | |
7 | * contributed to Berkeley. | |
8 | * | |
b480239a KB |
9 | * All advertising materials mentioning features or use of this software |
10 | * must display the following acknowledgement: | |
11 | * This product includes software developed by the University of | |
12 | * California, Lawrence Berkeley Laboratories. | |
13 | * | |
b744cdaa CT |
14 | * %sccs.include.redist.c% |
15 | * | |
b480239a | 16 | * @(#)kbd.h 7.2 (Berkeley) %G% |
b744cdaa CT |
17 | * |
18 | * from: $Header: kbd.h,v 1.4 92/06/17 05:35:48 torek Exp $ (LBL) | |
19 | */ | |
20 | ||
21 | /* | |
22 | * Keyboard `registers'. (This should be called kbd_reg.h but we need to | |
23 | * be compatible.) | |
24 | */ | |
25 | ||
26 | /* | |
27 | * Control codes sent from type 2, 3, and 4 keyboards. | |
28 | * | |
29 | * Note that KBD_RESET is followed by a keyboard ID, while KBD_IDLE is not. | |
30 | * KBD_IDLE does not take the place of any `up' transitions (it merely occurs | |
31 | * after them). | |
32 | */ | |
33 | #define KBD_RESET 0xff /* keyboard `reset' response */ | |
34 | #define KBD_IDLE 0x7f /* keyboard `all keys are up' code */ | |
35 | ||
36 | /* Keyboard IDs */ | |
37 | #define KB_SUN2 2 /* type 2 keyboard */ | |
38 | #define KB_SUN3 3 /* type 3 keyboard */ | |
39 | #define KB_SUN4 4 /* type 4 keyboard */ | |
40 | ||
41 | /* Key codes are in 0x00..0x7e; KBD_UP is set if the key goes up */ | |
42 | #define KBD_KEYMASK 0x7f /* keyboard key mask */ | |
43 | #define KBD_UP 0x80 /* keyboard `up' transition */ | |
44 | ||
45 | /* Keyboard codes needed to recognize the L1-A sequence */ | |
46 | #define KBD_L1 1 /* keyboard code for `L1' key */ | |
47 | #define KBD_A 77 /* keyboard code for `A' key */ | |
48 | ||
49 | /* Control codes sent to the various keyboards */ | |
50 | #define KBD_CMD_RESET 1 /* reset keyboard */ | |
51 | #define KBD_CMD_BELL 2 /* turn bell on */ | |
52 | #define KBD_CMD_NOBELL 3 /* turn bell off */ | |
53 | #define KBD_CMD_CLICK 10 /* turn keyclick on */ | |
54 | #define KBD_CMD_NOCLICK 11 /* turn keyclick off */ |