--- hatari/src/includes/ikbd.h 2019/04/01 07:09:43 1.1.1.2 +++ hatari/src/includes/ikbd.h 2019/04/01 07:12:14 1.1.1.4 @@ -1,7 +1,13 @@ /* - Hatari + Hatari - ikbd.h + + This file is distributed under the GNU Public License, version 2 or at + your option any later version. Read the file gpl.txt for details. */ +#ifndef HATARI_IKBD_H +#define HATARI_IKBD_H + #include /* Needed for SDLK_LAST */ @@ -13,10 +19,6 @@ typedef struct { } IKBD_COMMAND_PARAMS; /* Keyboard processor details */ -typedef struct { - int X,Y; /* Relative position of mouse */ - int PrevX,PrevY; /* Previous position */ -} REL_MOUSE; typedef struct { int X,Y; /* Position of mouse */ @@ -25,7 +27,8 @@ typedef struct { } ABS_MOUSE; typedef struct { - int DeltaX,DeltaY; /* XY mouse position delta after scale according to resoution */ + int dx, dy; /* Mouse delta to be added */ + int DeltaX,DeltaY; /* Final XY mouse position delta */ int XScale,YScale; /* Scale of mouse */ int XThreshold,YThreshold; /* Threshold */ unsigned char KeyCodeDeltaX,KeyCodeDeltaY; /* Delta X,Y for mouse keycode mode */ @@ -39,7 +42,6 @@ typedef struct { } JOY; typedef struct { - REL_MOUSE Rel; ABS_MOUSE Abs; MOUSE Mouse; JOY Joy; @@ -83,16 +85,12 @@ typedef struct { #define ACIA_STATUS_REGISTER__OVERRUN_ERROR 0x40 #define ACIA_STATUS_REGISTER__INTERRUPT_REQUEST 0x80 -extern unsigned char ACIAControlRegister; -extern unsigned char ACIAStatusRegister; -extern unsigned char ACIAByte; - extern KEYBOARD_PROCESSOR KeyboardProcessor; extern KEYBOARD Keyboard; extern void IKBD_Reset(BOOL bCold); extern void IKBD_MemorySnapShot_Capture(BOOL bSave); -extern void IKBD_SendAutoKeyboardCommands(); +extern void IKBD_SendAutoKeyboardCommands(void); extern void IKBD_InterruptHandler_ResetTimer(void); extern void IKBD_Cmd_NullFunction(void); @@ -129,3 +127,10 @@ extern void IKBD_InterruptHandler_ACIA(v extern void IKBD_SendByteToACIA(void); extern void IKBD_AddKeyToKeyboardBuffer(unsigned char Data); extern void IKBD_PressSTKey(unsigned char ScanCode,BOOL bPress); + +extern void IKBD_KeyboardControl_ReadByte(void); +extern void IKBD_KeyboardData_ReadByte(void); +extern void IKBD_KeyboardControl_WriteByte(void); +extern void IKBD_KeyboardData_WriteByte(void); + +#endif /* HATARI_IKBD_H */