Annotation of sys/dev/adb/keyboard.h, Revision 1.1
1.1 ! nbrk 1: /* $OpenBSD: keyboard.h,v 1.4 2006/03/10 20:13:50 miod Exp $ */
! 2: /* $NetBSD: keyboard.h,v 1.1 1998/05/15 10:15:54 tsubai Exp $ */
! 3:
! 4: /*-
! 5: * Copyright (C) 1993 Allen K. Briggs, Chris P. Caputo,
! 6: * Michael L. Finch, Bradley A. Grantham, and
! 7: * Lawrence A. Kesteloot
! 8: * All rights reserved.
! 9: *
! 10: * Redistribution and use in source and binary forms, with or without
! 11: * modification, are permitted provided that the following conditions
! 12: * are met:
! 13: * 1. Redistributions of source code must retain the above copyright
! 14: * notice, this list of conditions and the following disclaimer.
! 15: * 2. Redistributions in binary form must reproduce the above copyright
! 16: * notice, this list of conditions and the following disclaimer in the
! 17: * documentation and/or other materials provided with the distribution.
! 18: * 3. All advertising materials mentioning features or use of this software
! 19: * must display the following acknowledgement:
! 20: * This product includes software developed by the Alice Group.
! 21: * 4. The names of the Alice Group or any of its members may not be used
! 22: * to endorse or promote products derived from this software without
! 23: * specific prior written permission.
! 24: *
! 25: * THIS SOFTWARE IS PROVIDED BY THE ALICE GROUP ``AS IS'' AND ANY EXPRESS OR
! 26: * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
! 27: * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
! 28: * IN NO EVENT SHALL THE ALICE GROUP BE LIABLE FOR ANY DIRECT, INDIRECT,
! 29: * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
! 30: * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
! 31: * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
! 32: * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
! 33: * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
! 34: * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
! 35: */
! 36:
! 37: #define ADBK_CAPSLOCK 0x39
! 38: #define ADBK_RESET 0x7f
! 39:
! 40: #define ADBK_KEYVAL(key) ((key) & 0x7f)
! 41: #define ADBK_PRESS(key) (((key) & 0x80) == 0)
! 42: #define ADBK_KEYDOWN(key) (key)
! 43: #define ADBK_KEYUP(key) ((key) | 0x80)
! 44:
! 45: #ifndef KEYBOARD_ARRAY
! 46: extern unsigned char keyboard[128];
! 47: #else
! 48: #include <dev/wscons/wskbdraw.h>
! 49: unsigned char keyboard[128] = {
! 50: RAWKEY_a,
! 51: RAWKEY_s,
! 52: RAWKEY_d,
! 53: RAWKEY_f,
! 54: RAWKEY_h,
! 55: RAWKEY_g,
! 56: RAWKEY_z,
! 57: RAWKEY_x,
! 58: RAWKEY_c,
! 59: RAWKEY_v,
! 60: #ifdef FIX_SV_X_KBDBUG
! 61: RAWKEY_grave,
! 62: #else
! 63: RAWKEY_less,
! 64: #endif
! 65: RAWKEY_b,
! 66: RAWKEY_q,
! 67: RAWKEY_w,
! 68: RAWKEY_e,
! 69: RAWKEY_r,
! 70: RAWKEY_y,
! 71: RAWKEY_t,
! 72: RAWKEY_1,
! 73: RAWKEY_2,
! 74: RAWKEY_3,
! 75: RAWKEY_4,
! 76: RAWKEY_6,
! 77: RAWKEY_5,
! 78: RAWKEY_equal,
! 79: RAWKEY_9,
! 80: RAWKEY_7,
! 81: RAWKEY_minus,
! 82: RAWKEY_8,
! 83: RAWKEY_0,
! 84: RAWKEY_bracketright,
! 85: RAWKEY_o,
! 86: RAWKEY_u,
! 87: RAWKEY_bracketleft,
! 88: RAWKEY_i,
! 89: RAWKEY_p,
! 90: RAWKEY_Return,
! 91: RAWKEY_l,
! 92: RAWKEY_j,
! 93: RAWKEY_apostrophe,
! 94: RAWKEY_k,
! 95: RAWKEY_semicolon,
! 96: RAWKEY_backslash,
! 97: RAWKEY_comma,
! 98: RAWKEY_slash,
! 99: RAWKEY_n,
! 100: RAWKEY_m,
! 101: RAWKEY_period,
! 102: RAWKEY_Tab,
! 103: RAWKEY_space,
! 104: #ifdef FIX_SV_X_KBDBUG
! 105: RAWKEY_less,
! 106: #else
! 107: RAWKEY_grave,
! 108: #endif
! 109: RAWKEY_Delete,
! 110: RAWKEY_KP_Enter,
! 111: RAWKEY_Escape,
! 112: RAWKEY_Control_L,
! 113: 219, /* XXX */
! 114: RAWKEY_Shift_L,
! 115: RAWKEY_Caps_Lock,
! 116: RAWKEY_Alt_L,
! 117: RAWKEY_Left,
! 118: RAWKEY_Right,
! 119: RAWKEY_Down,
! 120: RAWKEY_Up,
! 121: 0, /* Fn */
! 122: 0,
! 123: RAWKEY_KP_Delete,
! 124: 0,
! 125: RAWKEY_KP_Multiply,
! 126: 0,
! 127: RAWKEY_KP_Add,
! 128: 0,
! 129: RAWKEY_Num_Lock,
! 130: 0,
! 131: 0,
! 132: 0,
! 133: RAWKEY_KP_Divide,
! 134: RAWKEY_KP_Enter,
! 135: 0,
! 136: RAWKEY_KP_Subtract,
! 137: 0,
! 138: 0,
! 139: RAWKEY_KP_Equal,
! 140: RAWKEY_KP_Insert,
! 141: RAWKEY_KP_End,
! 142: RAWKEY_KP_Down,
! 143: RAWKEY_KP_Next,
! 144: RAWKEY_KP_Left,
! 145: RAWKEY_KP_Begin,
! 146: RAWKEY_KP_Right,
! 147: RAWKEY_KP_Home,
! 148: 0,
! 149: RAWKEY_KP_Up,
! 150: RAWKEY_KP_Prior,
! 151: 0,
! 152: 0,
! 153: RAWKEY_KP_Delete,
! 154: RAWKEY_f5,
! 155: RAWKEY_f6,
! 156: RAWKEY_f7,
! 157: RAWKEY_f3,
! 158: RAWKEY_f8,
! 159: RAWKEY_f9,
! 160: 0,
! 161: RAWKEY_f11,
! 162: 0,
! 163: RAWKEY_Print_Screen,
! 164: RAWKEY_KP_Enter,
! 165: RAWKEY_Hold_Screen,
! 166: 0,
! 167: RAWKEY_f10,
! 168: 0,
! 169: RAWKEY_f12,
! 170: 0,
! 171: RAWKEY_Pause,
! 172: RAWKEY_Insert,
! 173: RAWKEY_Home,
! 174: RAWKEY_Prior,
! 175: RAWKEY_Delete,
! 176: RAWKEY_f4,
! 177: RAWKEY_End,
! 178: RAWKEY_f2,
! 179: RAWKEY_Next,
! 180: RAWKEY_f1,
! 181: 0,
! 182: 0,
! 183: 0,
! 184: 0,
! 185: 0
! 186: };
! 187: #endif /* KEYBOARD_ARRAY */
CVSweb