KEYBOARD.INC 4.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126
  1. ;
  2. ; Copyright 2020 Electronic Arts Inc.
  3. ;
  4. ; TiberianDawn.DLL and RedAlert.dll and corresponding source code is free
  5. ; software: you can redistribute it and/or modify it under the terms of
  6. ; the GNU General Public License as published by the Free Software Foundation,
  7. ; either version 3 of the License, or (at your option) any later version.
  8. ; TiberianDawn.DLL and RedAlert.dll and corresponding source code is distributed
  9. ; in the hope that it will be useful, but with permitted additional restrictions
  10. ; under Section 7 of the GPL. See the GNU General Public License in LICENSE.TXT
  11. ; distributed with this program. You should have received a copy of the
  12. ; GNU General Public License along with permitted additional restrictions
  13. ; with this program. If not, see [https://github.com/electronicarts/CnC_Remastered_Collection]>.
  14. ;***************************************************************************
  15. ;** C O N F I D E N T I A L --- W E S T W O O D A S S O C I A T E S **
  16. ;***************************************************************************
  17. ;* *
  18. ;* Project Name : Westwood 32 bit Library *
  19. ;* *
  20. ;* File Name : KEYBOARD.INC *
  21. ;* *
  22. ;* Programmer : Phil W. Gorrow *
  23. ;* *
  24. ;* Start Date : July 12, 1994 *
  25. ;* *
  26. ;* Last Update : July 12, 1994 [PWG] *
  27. ;* *
  28. ;*-------------------------------------------------------------------------*
  29. ;* Contains all the defines used by the keyboard interrupt for assembly *
  30. ;* includes. *
  31. ;* - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - *
  32. TRUE EQU 1 ; numerical true
  33. FALSE EQU 0 ; numerical false
  34. DEBUG EQU 1
  35. MAX_X_PIXEL EQU 319
  36. MAX_Y_PIXEL EQU 199
  37. KN_RESERVED1 EQU 14
  38. KN_RESERVED2 EQU 45
  39. KN_RESERVED3 EQU 56
  40. ; these two are reserved for AMIGA open and close.
  41. KN_LCOMM EQU 59
  42. KN_RCOMM EQU 63
  43. KN_LMOUSE EQU 65
  44. KN_RMOUSE EQU 66
  45. KN_JBUTTON1 EQU 67
  46. KN_JBUTTON2 EQU 68
  47. KN_J_UP EQU 69
  48. KN_J_RIGHT EQU 70
  49. KN_J_DOWN EQU 71
  50. KN_J_LEFT EQU 72
  51. KN_LEFT EQU 92
  52. KN_UPLEFT EQU 91
  53. KN_UP EQU 96
  54. KN_UPRIGHT EQU 101
  55. KN_RIGHT EQU 102
  56. KN_DOWNRIGHT EQU 103
  57. KN_DOWN EQU 98
  58. KN_DOWNLEFT EQU 93
  59. KN_CENTER EQU 97
  60. KN_INSERT EQU 99
  61. KN_DELETE EQU 104
  62. KN_RETURN EQU 43
  63. KN_SPACE EQU 61
  64. KN_KEYPAD_RETURN EQU 108
  65. ; these two are reserved for AMIGA K left and right paren
  66. KN_KLPAREN EQU 87
  67. KN_KRPAREN EQU 88
  68. KN_NUMLOCK EQU 90
  69. KN_SCROLLOCK EQU 125 ; key ignored by the logging system
  70. KN_MOUSE_MOVE EQU 45 ; Indicate a mouse move (for playback of logged data)
  71. ; ----------------------------------------------------------------
  72. ; flags used in Keyflags to customize keystroke interrupt.
  73. REPEATON EQU 0001H ; 1:all makes into buffer, 0:only 1st make
  74. TRACKEXT EQU 0002H ; 1:Home != keypad Home, 0:Home=keypad Home
  75. FILTERONLY EQU 0004H ; 1:Normal BIOS operation with filter
  76. CTRLSON EQU 0008H ; 1:pass scroll lock sequence into BIOS
  77. CTRLALTTURBO EQU 0010H ; 1:Allow turbo up and down in application
  78. CTRLCON EQU 0020H ; 1:pass stop code to BIOS
  79. SCROLLLOCKON EQU 0040H ; 1:pass scroll lock key into BIOS
  80. PAUSEON EQU 0080H ; 1:pass the pause key and seq to BIOS
  81. BREAKON EQU 0100H ; 1:pass the ctrl break seq to BIOS
  82. NONUMLOCK EQU 0200H ; 1:do NOT remap keypad to numbers
  83. TASKSWITCHABLE EQU 0400H ; 1:allows task switching keys thru ALT-TAB,
  84. ; ALT-ESC,CTRL-ESC
  85. PASSBREAKS EQU 0800H ; 1:Pass all break codes to keyboard buffer.
  86. KEYMOUSE EQU 1000H ; 1:Numeric keypad moves mouse
  87. SIMLBUTTON EQU 2000H ; 1:have space and enter keys simulate Left
  88. DEBUGINT EQU 4000H ; mouse button when KEYMOUSE is set
  89. SHIFTPRESS EQU 001H ; bit 0 for shift key pressed
  90. CTRLPRESS EQU 002H ; bit 1 for ctrl key pressed
  91. ALTPRESS EQU 004H ; bit 2 for alt key pressed
  92. KEYRELEASE EQU 008H ; bit 3 for key released
  93. NOTKEYRELEASE EQU 0F7H ; not of key released
  94. CAPSLOCK EQU 00001H ; bit 0 for caps locked
  95. NUMLOCK EQU 00002H ; bit 1 for num locked
  96. CLEARISR EQU 020H ; value to clear In Service Register
  97. DOS EQU 021H
  98. INTCHIP0 EQU 020H ; 8259 interrupt chip controller 0
  99. KEYCTRL EQU 061H ; control bits for KB sense data
  100. KEYDATA EQU 060H ; keyboard scan code port