static INTERRUPT_GEN( cpuB_interrupt ) { overdriv_state *state = device->machine().driver_data<overdriv_state>(); if (k053246_is_irq_enabled(state->m_k053246)) device_set_input_line(device, 4, HOLD_LINE); }
static INTERRUPT_GEN( cpuB_interrupt ) { overdriv_state *state = (overdriv_state *)device->machine->driver_data; if (k053246_is_irq_enabled(state->k053246)) cpu_set_input_line(device, 4, HOLD_LINE); }
static TIMER_DEVICE_CALLBACK( dbz_scanline ) { dbz_state *state = timer.machine().driver_data<dbz_state>(); int scanline = param; if(scanline == 256) // vblank-out irq cputag_set_input_line(timer.machine(), "maincpu", M68K_IRQ_2, ASSERT_LINE); if(scanline == 0 && k053246_is_irq_enabled(state->m_k053246)) // vblank-in irq cputag_set_input_line(timer.machine(), "maincpu", M68K_IRQ_4, HOLD_LINE); //auto-acks apparently }
static INTERRUPT_GEN( moo_interrupt ) { moo_state *state = device->machine().driver_data<moo_state>(); if (k053246_is_irq_enabled(state->m_k053246)) { moo_objdma(device->machine(), state->m_game_type); // schedule DMA end interrupt (delay shortened to catch up with V-blank) state->m_dmaend_timer->adjust(attotime::from_usec(MOO_DMADELAY)); } // trigger V-blank interrupt if (state->m_cur_control2 & 0x20) device_set_input_line(device, 5, HOLD_LINE); }
static INTERRUPT_GEN( dbz_interrupt ) { dbz_state *state = device->machine->driver_data<dbz_state>(); switch (cpu_getiloops(device)) { case 0: cpu_set_input_line(device, M68K_IRQ_2, HOLD_LINE); break; case 1: if (k053246_is_irq_enabled(state->k053246)) cpu_set_input_line(device, M68K_IRQ_4, HOLD_LINE); break; } }
static INTERRUPT_GEN( gijoe_interrupt ) { gijoe_state *state = device->machine->driver_data<gijoe_state>(); // global interrupt masking (*this game only) if (!k056832_is_irq_enabled(state->k056832, 0)) return; if (k053246_is_irq_enabled(state->k053246)) { gijoe_objdma(device->machine); // 42.7us(clr) + 341.3us(xfer) delay at 6Mhz dotclock timer_adjust_oneshot(state->dmadelay_timer, JOE_DMADELAY, 0); } // trigger V-blank interrupt if (state->cur_control2 & 0x0080) cpu_set_input_line(device, 5, HOLD_LINE); }
static TIMER_DEVICE_CALLBACK( xexex_interrupt ) { xexex_state *state = timer.machine().driver_data<xexex_state>(); int scanline = param; if (state->m_suspension_active) { state->m_suspension_active = 0; timer.machine().scheduler().trigger(state->m_resume_trigger); } if(scanline == 0) { // IRQ 6 is for test mode only if (state->m_cur_control2 & 0x0020) device_set_input_line(state->m_maincpu, 6, HOLD_LINE); } /* TODO: vblank is at 256! (enable CCU then have fun in fixing offsetted layers) */ if(scanline == 128) { if (k053246_is_irq_enabled(state->m_k053246)) { // OBJDMA starts at the beginning of V-blank xexex_objdma(timer.machine(), 0); // schedule DMA end interrupt state->m_dmadelay_timer->adjust(XE_DMADELAY); } // IRQ 4 is the V-blank interrupt. It controls color, sound and // vital game logics that shouldn't be interfered by frame-drop. if (state->m_cur_control2 & 0x0800) device_set_input_line(state->m_maincpu, 4, HOLD_LINE); } }