25 // Exports from JAGUAR.CPP
27 extern int32 jaguar_cpu_in_exec;
28 extern uint32 jaguar_mainRom_crc32;
29 extern char * jaguar_eeproms_path;
30 extern char * whoName[9];
32 void jaguar_init(void);
33 void jaguar_reset(void);
34 void jaguar_done(void);
36 uint8 JaguarReadByte(uint32 offset, uint32 who = UNKNOWN);
37 uint16 JaguarReadWord(uint32 offset, uint32 who = UNKNOWN);
38 uint32 JaguarReadLong(uint32 offset, uint32 who = UNKNOWN);
39 void JaguarWriteByte(uint32 offset, uint8 data, uint32 who = UNKNOWN);
40 void JaguarWriteWord(uint32 offset, uint16 data, uint32 who = UNKNOWN);
41 void JaguarWriteLong(uint32 offset, uint32 data, uint32 who = UNKNOWN);
43 uint32 jaguar_interrupt_handler_is_valid(uint32 i);
44 void jaguar_dasm(uint32 offset, uint32 qt);
46 void JaguarExecute(int16 * backbuffer, bool render);
48 // Some handy macros to help converting native endian to big endian (jaguar native)
51 #define SET32(r, a, v) r[(a)] = ((v) & 0xFF000000) >> 24, r[(a)+1] = ((v) & 0x00FF0000) >> 16, \
52 r[(a)+2] = ((v) & 0x0000FF00) >> 8, r[(a)+3] = (v) & 0x000000FF
53 #define GET32(r, a) ((r[(a)] << 24) | (r[(a)+1] << 16) | (r[(a)+2] << 8) | r[(a)+3])
54 #define SET16(r, a, v) r[(a)] = ((v) & 0xFF00) >> 8, r[(a)+1] = (v) & 0xFF
55 #define GET16(r, a) ((r[(a)] << 8) | r[(a)+1])
57 // Various clock rates
59 #define M68K_CLOCK_RATE_PAL 13296950
60 #define M68K_CLOCK_RATE_NTSC 13295453
61 #define RISC_CLOCK_RATE_PAL 26593900
62 #define RISC_CLOCK_RATE_NTSC 26590906
64 // Stuff for IRQ handling
69 //Temp debug stuff (will go away soon, so don't depend on these)
71 void DumpMainMemory(void);
72 uint8 * GetRamPtr(void);
74 #endif // __JAGUAR_H__