X-Git-Url: http://shamusworld.gotdns.org/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=src%2Fv6809.h;fp=src%2Fv6809.h;h=ae8a33754efbab92c42927d80e2b6ca511004993;hb=e3ad811139308bfe8a818cf5e42e7553785fea82;hp=39fc3f84638e86545644c4a2319f5f2d1af7c96e;hpb=0c6f353827a94eb52c21e677658000f98452b247;p=stargem2 diff --git a/src/v6809.h b/src/v6809.h index 39fc3f8..ae8a337 100755 --- a/src/v6809.h +++ b/src/v6809.h @@ -9,7 +9,7 @@ #ifndef __V6809_H__ #define __V6809_H__ -#include "types.h" +#include // Useful defines @@ -35,29 +35,29 @@ struct V6809REGS { - uint16 pc; // 6809 PC register - uint16 x; // 6809 X index register - uint16 y; // 6809 Y index register - uint16 s; // 6809 System stack pointer - uint16 u; // 6809 User stack pointer - uint8 cc; // 6809 Condition Code register - uint8 a; // 6809 A register - uint8 b; // 6809 B register - uint8 dp; // 6809 Direct Page register -// uint32 clock; // 6809 clock (@ 1 MHz, wraps at 71.5 minutes) - uint64 clock; // 6809 clock (@ 1 MHz, wraps at 570842 years) - uint8 (* RdMem)(uint16); // Address of uint8 read routine - void (* WrMem)(uint16, uint8); // Address of uint8 write routine - uint32 cpuFlags; // v6809 IRQ/RESET flags - uint32 clockOverrun; + uint16_t pc; // 6809 PC register + uint16_t x; // 6809 X index register + uint16_t y; // 6809 Y index register + uint16_t s; // 6809 System stack pointer + uint16_t u; // 6809 User stack pointer + uint8_t cc; // 6809 Condition Code register + uint8_t a; // 6809 A register + uint8_t b; // 6809 B register + uint8_t dp; // 6809 Direct Page register + uint64_t clock; // 6809 clock (@ 1 MHz, wraps at 570842 years) + uint8_t (* RdMem)(uint16_t); // Address of uint8 read routine + void (* WrMem)(uint16_t, uint8_t); // Address of uint8 write routine + uint32_t cpuFlags; // v6809 IRQ/RESET flags + uint32_t clockOverrun; }; // Function prototypes -void Execute6809(V6809REGS *, uint32); // Function to execute 6809 instructions -uint64 GetCurrentV6809Clock(void); // Get the clock of the currently executing CPU -uint16 GetCurrentV6809PC(void); // Get the PC of the currently executing CPU -void SetLineOfCurrentV6809(uint32 line); // Set a line of the currently executing CPU -void ClearLineOfCurrentV6809(uint32 line); // Clear a line of the currently executing CPU +void Execute6809(V6809REGS *, uint32_t); // Function to execute 6809 instructions +uint64_t GetCurrentV6809Clock(void); // Get the clock of the currently executing CPU +uint16_t GetCurrentV6809PC(void); // Get the PC of the currently executing CPU +void SetLineOfCurrentV6809(uint32_t line); // Set a line of the currently executing CPU +void ClearLineOfCurrentV6809(uint32_t line); // Clear a line of the currently executing CPU #endif // __V6809_H__ +