155106Storek /* 2*63318Sbostic * Copyright (c) 1992, 1993 3*63318Sbostic * The Regents of the University of California. All rights reserved. 455106Storek * 555106Storek * This software was developed by the Computer Systems Engineering group 655106Storek * at Lawrence Berkeley Laboratory under DARPA contract BG 91-66 and 755106Storek * contributed to Berkeley. 855106Storek * 955499Sbostic * All advertising materials mentioning features or use of this software 1055499Sbostic * must display the following acknowledgement: 1155499Sbostic * This product includes software developed by the University of 1259190Storek * California, Lawrence Berkeley Laboratory. 1355499Sbostic * 1455106Storek * %sccs.include.redist.c% 1555106Storek * 16*63318Sbostic * @(#)kbd.h 8.1 (Berkeley) 06/11/93 1755106Storek * 1859190Storek * from: $Header: kbd.h,v 1.5 92/11/26 01:15:33 torek Exp $ (LBL) 1955106Storek */ 2055106Storek 2155106Storek /* 2255106Storek * Keyboard `registers'. (This should be called kbd_reg.h but we need to 2355106Storek * be compatible.) 2455106Storek */ 2555106Storek 2655106Storek /* 2755106Storek * Control codes sent from type 2, 3, and 4 keyboards. 2855106Storek * 2955106Storek * Note that KBD_RESET is followed by a keyboard ID, while KBD_IDLE is not. 3055106Storek * KBD_IDLE does not take the place of any `up' transitions (it merely occurs 3155106Storek * after them). 3255106Storek */ 3355106Storek #define KBD_RESET 0xff /* keyboard `reset' response */ 3455106Storek #define KBD_IDLE 0x7f /* keyboard `all keys are up' code */ 3555106Storek 3655106Storek /* Keyboard IDs */ 3755106Storek #define KB_SUN2 2 /* type 2 keyboard */ 3855106Storek #define KB_SUN3 3 /* type 3 keyboard */ 3955106Storek #define KB_SUN4 4 /* type 4 keyboard */ 4055106Storek 4155106Storek /* Key codes are in 0x00..0x7e; KBD_UP is set if the key goes up */ 4255106Storek #define KBD_KEYMASK 0x7f /* keyboard key mask */ 4355106Storek #define KBD_UP 0x80 /* keyboard `up' transition */ 4455106Storek 4555106Storek /* Keyboard codes needed to recognize the L1-A sequence */ 4655106Storek #define KBD_L1 1 /* keyboard code for `L1' key */ 4755106Storek #define KBD_A 77 /* keyboard code for `A' key */ 4855106Storek 4955106Storek /* Control codes sent to the various keyboards */ 5055106Storek #define KBD_CMD_RESET 1 /* reset keyboard */ 5155106Storek #define KBD_CMD_BELL 2 /* turn bell on */ 5255106Storek #define KBD_CMD_NOBELL 3 /* turn bell off */ 5355106Storek #define KBD_CMD_CLICK 10 /* turn keyclick on */ 5455106Storek #define KBD_CMD_NOCLICK 11 /* turn keyclick off */ 55