Example #1
0
void m68000_init(void)
{
	C68k_Init(&C68K);
	C68k_Set_ReadB(&C68K, Memory_ReadB);
	C68k_Set_ReadW(&C68K, Memory_ReadW);
	C68k_Set_WriteB(&C68K, Memory_WriteB);
	C68k_Set_WriteW(&C68K, Memory_WriteW);
        C68k_Set_Fetch(&C68K, 0x000000, 0xbfffff, (UINT32)MEM);
        C68k_Set_Fetch(&C68K, 0xc00000, 0xc7ffff, (UINT32)GVRAM);
        C68k_Set_Fetch(&C68K, 0xe00000, 0xe7ffff, (UINT32)TVRAM);
        C68k_Set_Fetch(&C68K, 0xea0000, 0xea1fff, (UINT32)SCSIIPL);
        C68k_Set_Fetch(&C68K, 0xed0000, 0xed3fff, (UINT32)SRAM);
        C68k_Set_Fetch(&C68K, 0xf00000, 0xfbffff, (UINT32)FONT);
        C68k_Set_Fetch(&C68K, 0xfc0000, 0xffffff, (UINT32)IPL);
}
Example #2
0
void C68k_Init(c68k_struc *cpu, C68K_INT_CALLBACK *int_cb)
{
    memset(cpu, 0, sizeof(c68k_struc));

    C68k_Set_ReadB(cpu, C68k_Read8_Dummy);
    C68k_Set_ReadW(cpu, C68k_Read16_Dummy);

    C68k_Set_WriteB(cpu, C68k_Write8_Dummy);
    C68k_Set_WriteW(cpu, C68k_Write16_Dummy);

    C68k_Set_TAS_Hack(cpu, 0);

    //C68k_Set_Debug(cpu, NULL);

    if (int_cb) cpu->Interrupt_CallBack = int_cb;
    else cpu->Interrupt_CallBack = C68k_Interrupt_Ack_Dummy;
    cpu->Reset_CallBack = C68k_Reset_Dummy;
}
Example #3
0
void C68k_Init(c68k_struc *cpu, C68K_INT_CALLBACK *int_cb)
{
    memset(cpu, 0, sizeof(c68k_struc));

    C68k_Set_ReadB(cpu, C68k_Read_Dummy);
    C68k_Set_ReadW(cpu, C68k_Read_Dummy);

    C68k_Set_WriteB(cpu, C68k_Write_Dummy);
    C68k_Set_WriteW(cpu, C68k_Write_Dummy);

    if (int_cb) cpu->Interrupt_CallBack = int_cb;
    else cpu->Interrupt_CallBack = C68k_Interrupt_Ack_Dummy;
    cpu->Reset_CallBack = C68k_Reset_Dummy;

    // used to init JumpTable
    cpu->Status |= C68K_DISABLE;
    C68k_Exec(cpu, 0);
    
    cpu->Status &= ~C68K_DISABLE;
}
Example #4
0
bool MDDBG_Init(void)
{
 MDFNDBG_AddRegGroup(&M68K_RegsGroup);

 ASpace_Add(GetAddressSpaceBytes, PutAddressSpaceBytes, "cpu", "CPU Physical", 24);
 ASpace_Add(GetAddressSpaceBytes, PutAddressSpaceBytes, "ram", "Work RAM", 16);

 
 C68k_Init(&Main68K_BP, dbg_int_ack_callback);

 C68k_Set_TAS_Hack(&Main68K_BP, 1);

 C68k_Set_ReadB(&Main68K_BP, MDDBG_ReadMemory8);
 C68k_Set_ReadW(&Main68K_BP, MDDBG_ReadMemory16);

 C68k_Set_WriteB(&Main68K_BP, MDDBG_WriteMemory8);
 C68k_Set_WriteW(&Main68K_BP, MDDBG_WriteMemory16);

 MD_DebugMode = FALSE;

 return(TRUE);
}
Example #5
0
inline void M68K_Init(void)
{
#ifdef CPU68K_USE_MUSASHI
    // MUSASHI
    m68k_set_cpu_type(M68K_CPU_TYPE_68000);
    m68k_pulse_reset();
#endif

#ifdef CPU68K_USE_C68K
    // C68K
    C68k_Init(&C68K, NULL);

    C68k_Set_ReadB(&C68K, m68k_read_memory_8);
    C68k_Set_ReadW(&C68K, m68k_read_memory_16);

    C68k_Set_WriteB(&C68K, m68k_write_memory_8);
    C68k_Set_WriteW(&C68K, m68k_write_memory_16);
    
    C68k_Set_Fetch(&C68K, 0x000000, 0x1FFFFF, (u32) neogeo_prg_memory);
    C68k_Set_Fetch(&C68K, 0xC00000, 0xC7FFFF, (u32) neogeo_rom_memory);
    
    C68k_Reset(&C68K);
#endif
}
Example #6
0
static void M68KC68KSetWriteB(M68K_WRITE *Func) {
	C68k_Set_WriteB(&C68K, Func);
}