main(int argc, char *argv[])\r
{\r
ControlInfo control;\r
+ extern boolean Keyboard[NumCodes];\r
IN_Startup();\r
IN_Default(0,ctrl_Keyboard);\r
- IN_ReadControl(0,&control);\r
+ while(!IN_qb(sc_Escape))\r
+ {\r
+ IN_ReadControl(0,&control);\r
+// printf("%u\n", Keyboard[sc_Escape]);\r
+\r
+ }\r
IN_Shutdown();\r
}\r
#include "src/lib/16_in.h"
// Internal routines
-
///////////////////////////////////////////////////////////////////////////
//
// INL_KeyService() - Handles a keyboard interrupt (key up/down)
INL_KeyService(void)
{
static boolean special;
- byte k,c,
- temp;
+ byte k,c;
+ register byte temp;
k = inp(0x60); // Get the scan code
if (INL_KeyHook && !special)
INL_KeyHook();
+ #ifdef TESTKEYIN
+ printf("%c %x %u\n", c, k, Keyboard[k]);
+ #endif
outp(0x20,0x20);
}
} while (TimeCount - lasttime < delay);
return(false);
}
+
+boolean IN_qb(byte kee)
+{
+ if(Keyboard[kee]==true) return 1;
+ else return 0;
+}
#define __DEBUG_InputMgr__\r
//++++#endif\r
\r
-#define DOMO\r
+//#define DOMO\r
+#define TESTKEYIN\r
\r
#define KeyInt 9 // The keyboard ISR number\r
\r
extern word IN_GetJoyButtonsDB(word joy);\r
\r
\r
-//static void interrupt INL_KeyService(void);\r
+void interrupt INL_KeyService(void);\r
+boolean IN_qb(byte kee);\r
#endif\r