1 // chip dip 2 UINT8 cchip_asic_read(UINT32 offset); 3 void cchip_asic_write68k(UINT32 offset, UINT16 data); 4 void cchip_68k_write(UINT16 address, UINT8 data); 5 UINT8 cchip_68k_read(UINT16 address); 6 7 void cchip_interrupt(); 8 void cchip_loadports(UINT8 pa, UINT8 pb, UINT8 pc, UINT8 padc); 9 10 void cchip_init(); 11 void cchip_exit(); 12 INT32 cchip_run(INT32 cyc); 13 void cchip_reset(); 14 INT32 cchip_scan(INT32 nAction); 15 16 #define cchip_Run cchip_run 17 18 extern UINT8 *cchip_rom; 19 extern UINT8 *cchip_eeprom; 20 extern UINT8 cchip_active; 21 22 // Handy macro's. 8/16bit 68k compatible 23 #define CCHIP_READ(base) \ 24 if (a >= (0x0000 | base) && a <= (0x07ff | base)) \ 25 return cchip_68k_read((a & 0x7ff) >> 1); \ 26 \ 27 if (a >= (0x0800 | base) && a <= (0x0fff | base)) \ 28 return cchip_asic_read((a & 0x7ff) >> 1); 29 30 #define CCHIP_WRITE(base) \ 31 if (a >= (0x0000 | base) && a <= (0x07ff | base)) { \ 32 cchip_68k_write((a & 0x7ff) >> 1, d); \ 33 return; \ 34 } \ 35 if (a >= (0x0800 | base) && a <= (0x0fff | base)) { \ 36 cchip_asic_write68k((a & 0x7ff) >> 1, d); \ 37 return; \ 38 } 39