MCFG_CPU_VBLANK_INT line callback replacements for many old Konami games (nw)

This commit is contained in:
AJR 2018-03-28 22:19:12 -04:00
parent af143199f8
commit 5cf9db8e6c
23 changed files with 94 additions and 84 deletions

View File

@ -70,6 +70,7 @@ This bug is due to 380_r02.6h, it differs from 380_q02.6h by 2 bytes, at
void circusc_state::machine_start()
{
save_item(NAME(m_sn_latch));
save_item(NAME(m_irq_mask));
}
void circusc_state::machine_reset()
@ -337,10 +338,10 @@ static DISCRETE_SOUND_START( circusc )
DISCRETE_SOUND_END
INTERRUPT_GEN_MEMBER(circusc_state::vblank_irq)
WRITE_LINE_MEMBER(circusc_state::vblank_irq)
{
if (m_irq_mask)
device.execute().set_input_line(M6809_IRQ_LINE, ASSERT_LINE);
if (state && m_irq_mask)
m_maincpu->set_input_line(M6809_IRQ_LINE, ASSERT_LINE);
}
MACHINE_CONFIG_START(circusc_state::circusc)
@ -348,7 +349,6 @@ MACHINE_CONFIG_START(circusc_state::circusc)
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", KONAMI1, 2048000) /* 2 MHz? */
MCFG_CPU_PROGRAM_MAP(circusc_map)
MCFG_CPU_VBLANK_INT_DRIVER("screen", circusc_state, vblank_irq)
MCFG_DEVICE_ADD("mainlatch", LS259, 0) // 2C
MCFG_ADDRESSABLE_LATCH_Q0_OUT_CB(WRITELINE(circusc_state, flipscreen_w)) // FLIP
@ -373,6 +373,7 @@ MACHINE_CONFIG_START(circusc_state::circusc)
MCFG_SCREEN_VISIBLE_AREA(0*8, 32*8-1, 2*8, 30*8-1)
MCFG_SCREEN_UPDATE_DRIVER(circusc_state, screen_update_circusc)
MCFG_SCREEN_PALETTE("palette")
MCFG_SCREEN_VBLANK_CALLBACK(WRITELINE(circusc_state, vblank_irq))
MCFG_GFXDECODE_ADD("gfxdecode", "palette", circusc)
MCFG_PALETTE_ADD("palette", 16*16+16*16)

View File

@ -22,16 +22,13 @@
#include "speaker.h"
INTERRUPT_GEN_MEMBER(ddribble_state::ddribble_interrupt_0)
WRITE_LINE_MEMBER(ddribble_state::vblank_irq)
{
if (m_int_enable_0)
device.execute().set_input_line(M6809_FIRQ_LINE, HOLD_LINE);
}
if (state && m_int_enable_0)
m_maincpu->set_input_line(M6809_FIRQ_LINE, HOLD_LINE);
INTERRUPT_GEN_MEMBER(ddribble_state::ddribble_interrupt_1)
{
if (m_int_enable_1)
device.execute().set_input_line(M6809_FIRQ_LINE, HOLD_LINE);
if (state && m_int_enable_1)
m_cpu1->set_input_line(M6809_FIRQ_LINE, HOLD_LINE);
}
@ -265,11 +262,9 @@ MACHINE_CONFIG_START(ddribble_state::ddribble)
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", MC6809E, XTAL(18'432'000)/12) /* verified on pcb */
MCFG_CPU_PROGRAM_MAP(cpu0_map)
MCFG_CPU_VBLANK_INT_DRIVER("screen", ddribble_state, ddribble_interrupt_0)
MCFG_CPU_ADD("cpu1", MC6809E, XTAL(18'432'000)/12) /* verified on pcb */
MCFG_CPU_PROGRAM_MAP(cpu1_map)
MCFG_CPU_VBLANK_INT_DRIVER("screen", ddribble_state, ddribble_interrupt_1)
MCFG_CPU_ADD("cpu2", MC6809E, XTAL(18'432'000)/12) /* verified on pcb */
MCFG_CPU_PROGRAM_MAP(cpu2_map)
@ -288,6 +283,7 @@ MACHINE_CONFIG_START(ddribble_state::ddribble)
MCFG_SCREEN_VISIBLE_AREA(0*8, 64*8-1, 2*8, 30*8-1) */
MCFG_SCREEN_UPDATE_DRIVER(ddribble_state, screen_update_ddribble)
MCFG_SCREEN_PALETTE("palette")
MCFG_SCREEN_VBLANK_CALLBACK(WRITELINE(ddribble_state, vblank_irq))
MCFG_GFXDECODE_ADD("gfxdecode", "palette", ddribble)
MCFG_PALETTE_ADD("palette", 64 + 256)

View File

@ -465,16 +465,13 @@ void gyruss_state::machine_start()
save_item(NAME(m_slave_irq_mask));
}
INTERRUPT_GEN_MEMBER(gyruss_state::master_vblank_irq)
WRITE_LINE_MEMBER(gyruss_state::vblank_irq)
{
if (m_master_nmi_mask)
device.execute().set_input_line(INPUT_LINE_NMI, ASSERT_LINE);
}
if (state && m_master_nmi_mask)
m_maincpu->set_input_line(INPUT_LINE_NMI, ASSERT_LINE);
INTERRUPT_GEN_MEMBER(gyruss_state::slave_vblank_irq)
{
if (m_slave_irq_mask)
device.execute().set_input_line(0, ASSERT_LINE);
if (state && m_slave_irq_mask)
m_subcpu->set_input_line(0, ASSERT_LINE);
}
MACHINE_CONFIG_START(gyruss_state::gyruss)
@ -482,11 +479,9 @@ MACHINE_CONFIG_START(gyruss_state::gyruss)
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", Z80, MASTER_CLOCK/6) /* 3.072 MHz */
MCFG_CPU_PROGRAM_MAP(main_cpu1_map)
MCFG_CPU_VBLANK_INT_DRIVER("screen", gyruss_state, master_vblank_irq)
MCFG_CPU_ADD("sub", KONAMI1, MASTER_CLOCK/12) /* 1.536 MHz */
MCFG_CPU_PROGRAM_MAP(main_cpu2_map)
MCFG_CPU_VBLANK_INT_DRIVER("screen", gyruss_state, slave_vblank_irq)
MCFG_CPU_ADD("audiocpu", Z80, SOUND_CLOCK/4) /* 3.579545 MHz */
MCFG_CPU_PROGRAM_MAP(audio_cpu1_map)
@ -511,6 +506,7 @@ MACHINE_CONFIG_START(gyruss_state::gyruss)
MCFG_SCREEN_RAW_PARAMS(PIXEL_CLOCK, HTOTAL, HBEND, HBSTART, VTOTAL, VBEND, VBSTART)
MCFG_SCREEN_UPDATE_DRIVER(gyruss_state, screen_update_gyruss)
MCFG_SCREEN_PALETTE("palette")
MCFG_SCREEN_VBLANK_CALLBACK(WRITELINE(gyruss_state, vblank_irq))
MCFG_GFXDECODE_ADD("gfxdecode", "palette", gyruss)
MCFG_PALETTE_ADD("palette", 16*4+16*16)

View File

@ -289,10 +289,10 @@ static GFXDECODE_START( roadf )
GFXDECODE_ENTRY( "gfx2", 0, roadf_charlayout, 16*16, 16 )
GFXDECODE_END
INTERRUPT_GEN_MEMBER(hyperspt_state::vblank_irq)
WRITE_LINE_MEMBER(hyperspt_state::vblank_irq)
{
if(m_irq_mask)
device.execute().set_input_line(0, ASSERT_LINE);
if (state && m_irq_mask)
m_maincpu->set_input_line(0, ASSERT_LINE);
}
MACHINE_CONFIG_START(hyperspt_state::hyperspt)
@ -300,7 +300,6 @@ MACHINE_CONFIG_START(hyperspt_state::hyperspt)
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", KONAMI1, XTAL(18'432'000)/12) /* verified on pcb */
MCFG_CPU_PROGRAM_MAP(hyperspt_map)
MCFG_CPU_VBLANK_INT_DRIVER("screen", hyperspt_state, vblank_irq)
MCFG_CPU_ADD("audiocpu", Z80,XTAL(14'318'181)/4) /* verified on pcb */
MCFG_CPU_PROGRAM_MAP(hyperspt_sound_map)
@ -326,6 +325,7 @@ MACHINE_CONFIG_START(hyperspt_state::hyperspt)
MCFG_SCREEN_VISIBLE_AREA(0*8, 32*8-1, 2*8, 30*8-1)
MCFG_SCREEN_UPDATE_DRIVER(hyperspt_state, screen_update)
MCFG_SCREEN_PALETTE("palette")
MCFG_SCREEN_VBLANK_CALLBACK(WRITELINE(hyperspt_state, vblank_irq))
MCFG_GFXDECODE_ADD("gfxdecode", "palette", hyperspt)
MCFG_PALETTE_ADD("palette", 16*16+16*16)

View File

@ -316,11 +316,11 @@ GFXDECODE_END
*
*************************************/
INTERRUPT_GEN_MEMBER(jackal_state::jackal_interrupt)
WRITE_LINE_MEMBER(jackal_state::vblank_irq)
{
if (m_irq_enable)
if (state && m_irq_enable)
{
device.execute().set_input_line(0, HOLD_LINE);
m_mastercpu->set_input_line(0, HOLD_LINE);
m_slavecpu->set_input_line(INPUT_LINE_NMI, PULSE_LINE);
}
}
@ -362,7 +362,6 @@ MACHINE_CONFIG_START(jackal_state::jackal)
/* basic machine hardware */
MCFG_CPU_ADD("master", MC6809E, MASTER_CLOCK/12) // verified on pcb
MCFG_CPU_PROGRAM_MAP(master_map)
MCFG_CPU_VBLANK_INT_DRIVER("screen", jackal_state, jackal_interrupt)
MCFG_CPU_ADD("slave", MC6809E, MASTER_CLOCK/12) // verified on pcb
MCFG_CPU_PROGRAM_MAP(slave_map)
@ -379,6 +378,7 @@ MACHINE_CONFIG_START(jackal_state::jackal)
MCFG_SCREEN_VISIBLE_AREA(1*8, 31*8-1, 2*8, 30*8-1)
MCFG_SCREEN_UPDATE_DRIVER(jackal_state, screen_update_jackal)
MCFG_SCREEN_PALETTE("palette")
MCFG_SCREEN_VBLANK_CALLBACK(WRITELINE(jackal_state, vblank_irq))
MCFG_GFXDECODE_ADD("gfxdecode", "palette", jackal)
MCFG_PALETTE_ADD("palette", 0x300)

View File

@ -131,7 +131,7 @@ public:
DECLARE_MACHINE_START(junofrst);
DECLARE_MACHINE_RESET(junofrst);
INTERRUPT_GEN_MEMBER(_30hz_irq);
DECLARE_WRITE_LINE_MEMBER(_30hz_irq);
void junofrst(machine_config &config);
void audio_map(address_map &map);
void main_map(address_map &map);
@ -385,12 +385,15 @@ MACHINE_RESET_MEMBER(junofrst_state,junofrst)
m_blitterdata[3] = 0;
}
INTERRUPT_GEN_MEMBER(junofrst_state::_30hz_irq)
WRITE_LINE_MEMBER(junofrst_state::_30hz_irq)
{
/* flip flops cause the interrupt to be signalled every other frame */
m_irq_toggle ^= 1;
if (m_irq_toggle && m_irq_enable)
device.execute().set_input_line(0, ASSERT_LINE);
if (state)
{
m_irq_toggle ^= 1;
if (m_irq_toggle && m_irq_enable)
m_maincpu->set_input_line(0, ASSERT_LINE);
}
}
MACHINE_CONFIG_START(junofrst_state::junofrst)
@ -398,7 +401,6 @@ MACHINE_CONFIG_START(junofrst_state::junofrst)
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", KONAMI1, 1500000) /* 1.5 MHz ??? */
MCFG_CPU_PROGRAM_MAP(main_map)
MCFG_CPU_VBLANK_INT_DRIVER("screen", junofrst_state, _30hz_irq)
MCFG_CPU_ADD("audiocpu", Z80,14318000/8) /* 1.78975 MHz */
MCFG_CPU_PROGRAM_MAP(audio_map)
@ -432,6 +434,7 @@ MACHINE_CONFIG_START(junofrst_state::junofrst)
MCFG_SCREEN_SIZE(32*8, 32*8)
MCFG_SCREEN_VISIBLE_AREA(0*8, 32*8-1, 2*8, 30*8-1) /* not sure about the visible area */
MCFG_SCREEN_UPDATE_DRIVER(junofrst_state, screen_update_tutankhm)
MCFG_SCREEN_VBLANK_CALLBACK(WRITELINE(junofrst_state, _30hz_irq))
/* sound hardware */
MCFG_SPEAKER_STANDARD_MONO("speaker")

View File

@ -280,6 +280,7 @@ void megazone_state::machine_start()
{
save_item(NAME(m_flipscreen));
save_item(NAME(m_i8039_status));
save_item(NAME(m_irq_mask));
}
void megazone_state::machine_reset()
@ -287,10 +288,13 @@ void megazone_state::machine_reset()
m_i8039_status = 0;
}
INTERRUPT_GEN_MEMBER(megazone_state::vblank_irq)
WRITE_LINE_MEMBER(megazone_state::vblank_irq)
{
if(m_irq_mask)
device.execute().set_input_line(0, HOLD_LINE);
if (state && m_irq_mask)
m_maincpu->set_input_line(0, HOLD_LINE);
if (state)
m_audiocpu->set_input_line(0, HOLD_LINE);
}
@ -299,12 +303,10 @@ MACHINE_CONFIG_START(megazone_state::megazone)
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", KONAMI1, XTAL(18'432'000)/9) /* 2.048 MHz */
MCFG_CPU_PROGRAM_MAP(megazone_map)
MCFG_CPU_VBLANK_INT_DRIVER("screen", megazone_state, vblank_irq)
MCFG_CPU_ADD("audiocpu", Z80, XTAL(18'432'000)/6) /* Z80 Clock is derived from the H1 signal */
MCFG_CPU_PROGRAM_MAP(megazone_sound_map)
MCFG_CPU_IO_MAP(megazone_sound_io_map)
MCFG_CPU_VBLANK_INT_DRIVER("screen", megazone_state, irq0_line_hold)
MCFG_CPU_ADD("daccpu", I8039, XTAL(14'318'181)/2) /* 7.15909MHz */
MCFG_CPU_PROGRAM_MAP(megazone_i8039_map)
@ -330,6 +332,7 @@ MACHINE_CONFIG_START(megazone_state::megazone)
MCFG_SCREEN_VISIBLE_AREA(0*8, 36*8-1, 2*8, 30*8-1)
MCFG_SCREEN_UPDATE_DRIVER(megazone_state, screen_update_megazone)
MCFG_SCREEN_PALETTE("palette")
MCFG_SCREEN_VBLANK_CALLBACK(WRITELINE(megazone_state, vblank_irq))
MCFG_GFXDECODE_ADD("gfxdecode", "palette", megazone)
MCFG_PALETTE_ADD("palette", 16*16+16*16)

View File

@ -252,10 +252,10 @@ void mikie_state::machine_reset()
m_palettebank = 0;
}
INTERRUPT_GEN_MEMBER(mikie_state::vblank_irq)
WRITE_LINE_MEMBER(mikie_state::vblank_irq)
{
if (m_irq_mask)
device.execute().set_input_line(M6809_IRQ_LINE, ASSERT_LINE);
if (state && m_irq_mask)
m_maincpu->set_input_line(M6809_IRQ_LINE, ASSERT_LINE);
}
MACHINE_CONFIG_START(mikie_state::mikie)
@ -263,7 +263,6 @@ MACHINE_CONFIG_START(mikie_state::mikie)
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", MC6809E, OSC/12) // 9A (surface scratched)
MCFG_CPU_PROGRAM_MAP(mikie_map)
MCFG_CPU_VBLANK_INT_DRIVER("screen", mikie_state, vblank_irq)
MCFG_CPU_ADD("audiocpu", Z80, CLK) // 4E (surface scratched)
MCFG_CPU_PROGRAM_MAP(sound_map)
@ -286,6 +285,7 @@ MACHINE_CONFIG_START(mikie_state::mikie)
MCFG_SCREEN_VISIBLE_AREA(0*8, 32*8-1, 2*8, 30*8-1)
MCFG_SCREEN_UPDATE_DRIVER(mikie_state, screen_update_mikie)
MCFG_SCREEN_PALETTE("palette")
MCFG_SCREEN_VBLANK_CALLBACK(WRITELINE(mikie_state, vblank_irq))
MCFG_GFXDECODE_ADD("gfxdecode", "palette", mikie)
MCFG_PALETTE_ADD("palette", 16*8*16+16*8*16)

View File

@ -233,6 +233,13 @@ WRITE_LINE_MEMBER(rallyx_state::irq_mask_w)
m_maincpu->set_input_line(0, CLEAR_LINE);
}
WRITE_LINE_MEMBER(rallyx_state::nmi_mask_w)
{
m_main_irq_mask = state;
if (!state)
m_maincpu->set_input_line(INPUT_LINE_NMI, CLEAR_LINE);
}
WRITE_LINE_MEMBER(rallyx_state::sound_on_w)
{
@ -804,18 +811,19 @@ MACHINE_START_MEMBER(rallyx_state,rallyx)
{
save_item(NAME(m_last_bang));
save_item(NAME(m_stars_enable));
save_item(NAME(m_main_irq_mask));
}
INTERRUPT_GEN_MEMBER(rallyx_state::rallyx_vblank_irq)
WRITE_LINE_MEMBER(rallyx_state::rallyx_vblank_irq)
{
if (m_main_irq_mask)
device.execute().set_input_line(0, ASSERT_LINE);
if (state && m_main_irq_mask)
m_maincpu->set_input_line(0, ASSERT_LINE);
}
INTERRUPT_GEN_MEMBER(rallyx_state::jungler_vblank_irq)
WRITE_LINE_MEMBER(rallyx_state::jungler_vblank_irq)
{
if (m_main_irq_mask)
device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
if (state && m_main_irq_mask)
m_maincpu->set_input_line(INPUT_LINE_NMI, ASSERT_LINE);
}
MACHINE_CONFIG_START(rallyx_state::rallyx)
@ -824,7 +832,6 @@ MACHINE_CONFIG_START(rallyx_state::rallyx)
MCFG_CPU_ADD("maincpu", Z80, MASTER_CLOCK/6) /* 3.072 MHz */
MCFG_CPU_PROGRAM_MAP(rallyx_map)
MCFG_CPU_IO_MAP(io_map)
MCFG_CPU_VBLANK_INT_DRIVER("screen", rallyx_state, rallyx_vblank_irq)
MCFG_DEVICE_ADD("mainlatch", LS259, 0) // 259 at 12M or 4099 at 11M on Logic Board I
MCFG_ADDRESSABLE_LATCH_Q0_OUT_CB(WRITELINE(rallyx_state, bang_w)) // BANG
@ -848,6 +855,7 @@ MACHINE_CONFIG_START(rallyx_state::rallyx)
MCFG_SCREEN_VISIBLE_AREA(0*8, 36*8-1, 2*8, 30*8-1)
MCFG_SCREEN_UPDATE_DRIVER(rallyx_state, screen_update_rallyx)
MCFG_SCREEN_PALETTE("palette")
MCFG_SCREEN_VBLANK_CALLBACK(WRITELINE(rallyx_state, rallyx_vblank_irq))
MCFG_GFXDECODE_ADD("gfxdecode", "palette", rallyx)
@ -876,11 +884,10 @@ MACHINE_CONFIG_START(rallyx_state::jungler)
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", Z80, MASTER_CLOCK/6) /* 3.072 MHz */
MCFG_CPU_PROGRAM_MAP(jungler_map)
MCFG_CPU_VBLANK_INT_DRIVER("screen", rallyx_state, jungler_vblank_irq)
MCFG_DEVICE_ADD("mainlatch", LS259, 0) // 1C on Loco-Motion
MCFG_ADDRESSABLE_LATCH_Q0_OUT_CB(DEVWRITELINE("timeplt_audio", timeplt_audio_device, sh_irqtrigger_w)) // SOUNDON
MCFG_ADDRESSABLE_LATCH_Q1_OUT_CB(WRITELINE(rallyx_state, irq_mask_w)) // INTST
MCFG_ADDRESSABLE_LATCH_Q1_OUT_CB(WRITELINE(rallyx_state, nmi_mask_w)) // INTST
MCFG_ADDRESSABLE_LATCH_Q2_OUT_CB(DEVWRITELINE("timeplt_audio", timeplt_audio_device, mute_w)) // MUT
MCFG_ADDRESSABLE_LATCH_Q3_OUT_CB(WRITELINE(rallyx_state, flip_screen_w)) // FLIP
MCFG_ADDRESSABLE_LATCH_Q4_OUT_CB(WRITELINE(rallyx_state, coin_counter_1_w)) // OUT1
@ -900,6 +907,7 @@ MACHINE_CONFIG_START(rallyx_state::jungler)
MCFG_SCREEN_VISIBLE_AREA(0*8, 36*8-1, 2*8, 30*8-1)
MCFG_SCREEN_UPDATE_DRIVER(rallyx_state, screen_update_jungler)
MCFG_SCREEN_PALETTE("palette")
MCFG_SCREEN_VBLANK_CALLBACK(WRITELINE(rallyx_state, jungler_vblank_irq))
MCFG_GFXDECODE_ADD("gfxdecode", "palette", jungler)

View File

@ -188,10 +188,10 @@ static GFXDECODE_START( sbasketb )
GFXDECODE_ENTRY( "gfx2", 0, spritelayout, 16*16, 16*16 )
GFXDECODE_END
INTERRUPT_GEN_MEMBER(sbasketb_state::vblank_irq)
WRITE_LINE_MEMBER(sbasketb_state::vblank_irq)
{
if(m_irq_mask)
device.execute().set_input_line(0, HOLD_LINE);
if (state && m_irq_mask)
m_maincpu->set_input_line(0, HOLD_LINE);
}
MACHINE_CONFIG_START(sbasketb_state::sbasketb)
@ -199,7 +199,6 @@ MACHINE_CONFIG_START(sbasketb_state::sbasketb)
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", KONAMI1, 1400000) /* 1.400 MHz ??? */
MCFG_CPU_PROGRAM_MAP(sbasketb_map)
MCFG_CPU_VBLANK_INT_DRIVER("screen", sbasketb_state, vblank_irq)
MCFG_CPU_ADD("audiocpu", Z80, XTAL(14'318'181) / 4) /* 3.5795 MHz */
MCFG_CPU_PROGRAM_MAP(sbasketb_sound_map)
@ -223,6 +222,7 @@ MACHINE_CONFIG_START(sbasketb_state::sbasketb)
MCFG_SCREEN_VISIBLE_AREA(0*8, 32*8-1, 2*8, 30*8-1)
MCFG_SCREEN_UPDATE_DRIVER(sbasketb_state, screen_update_sbasketb)
MCFG_SCREEN_PALETTE("palette")
MCFG_SCREEN_VBLANK_CALLBACK(WRITELINE(sbasketb_state, vblank_irq))
MCFG_GFXDECODE_ADD("gfxdecode", "palette", sbasketb)
MCFG_PALETTE_ADD("palette", 16*16+16*16*16)
@ -252,7 +252,6 @@ MACHINE_CONFIG_START(sbasketb_state::sbasketbu)
MCFG_DEVICE_REMOVE("maincpu")
MCFG_CPU_ADD("maincpu", MC6809E, 1400000) /* 6809E at 1.400 MHz ??? */
MCFG_CPU_PROGRAM_MAP(sbasketb_map)
MCFG_CPU_VBLANK_INT_DRIVER("screen", sbasketb_state, vblank_irq)
MACHINE_CONFIG_END

View File

@ -52,9 +52,9 @@ WRITE8_MEMBER(scotrsht_state::ctrl_w)
flip_screen_set(data & 0x08);
}
INTERRUPT_GEN_MEMBER(scotrsht_state::interrupt)
WRITE_LINE_MEMBER(scotrsht_state::vblank_irq)
{
if (m_irq_enable)
if (state && m_irq_enable)
m_maincpu->set_input_line(0, HOLD_LINE);
}
@ -192,7 +192,6 @@ MACHINE_CONFIG_START(scotrsht_state::scotrsht)
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", MC6809E, 18432000/6) /* 3.072 MHz */
MCFG_CPU_PROGRAM_MAP(scotrsht_map)
MCFG_CPU_VBLANK_INT_DRIVER("screen", scotrsht_state, interrupt)
MCFG_CPU_ADD("audiocpu", Z80, 18432000/6) /* 3.072 MHz */
MCFG_CPU_PROGRAM_MAP(scotrsht_sound_map)
@ -208,6 +207,7 @@ MACHINE_CONFIG_START(scotrsht_state::scotrsht)
MCFG_SCREEN_VISIBLE_AREA(0*8, 32*8-1, 2*8, 30*8-1)
MCFG_SCREEN_UPDATE_DRIVER(scotrsht_state, screen_update)
MCFG_SCREEN_PALETTE("palette")
MCFG_SCREEN_VBLANK_CALLBACK(WRITELINE(scotrsht_state, vblank_irq))
MCFG_GFXDECODE_ADD("gfxdecode", "palette", scotrsht)
MCFG_PALETTE_ADD("palette", 16*8*16+16*8*16)

View File

@ -67,12 +67,15 @@
*
*************************************/
INTERRUPT_GEN_MEMBER(tutankhm_state::tutankhm_interrupt)
WRITE_LINE_MEMBER(tutankhm_state::vblank_irq)
{
/* flip flops cause the interrupt to be signalled every other frame */
m_irq_toggle ^= 1;
if (m_irq_toggle && m_irq_enable)
device.execute().set_input_line(0, ASSERT_LINE);
if (state)
{
m_irq_toggle ^= 1;
if (m_irq_toggle && m_irq_enable)
m_maincpu->set_input_line(0, ASSERT_LINE);
}
}
@ -228,7 +231,6 @@ MACHINE_CONFIG_START(tutankhm_state::tutankhm)
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", MC6809E, XTAL(18'432'000)/12) /* 1.5 MHz ??? */
MCFG_CPU_PROGRAM_MAP(main_map)
MCFG_CPU_VBLANK_INT_DRIVER("screen", tutankhm_state, tutankhm_interrupt)
MCFG_MACHINE_START_OVERRIDE(tutankhm_state,tutankhm)
MCFG_MACHINE_RESET_OVERRIDE(tutankhm_state,tutankhm)
@ -252,6 +254,7 @@ MACHINE_CONFIG_START(tutankhm_state::tutankhm)
MCFG_SCREEN_SIZE(32*8, 32*8)
MCFG_SCREEN_VISIBLE_AREA(0*8, 32*8-1, 2*8, 30*8-1) /* not sure about the visible area */
MCFG_SCREEN_UPDATE_DRIVER(tutankhm_state, screen_update_tutankhm)
MCFG_SCREEN_VBLANK_CALLBACK(WRITELINE(tutankhm_state, vblank_irq))
MCFG_PALETTE_ADD("palette", 16)
MCFG_PALETTE_FORMAT(BBGGGRRR)

View File

@ -68,7 +68,7 @@ public:
virtual void video_start() override;
DECLARE_PALETTE_INIT(circusc);
uint32_t screen_update_circusc(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
INTERRUPT_GEN_MEMBER(vblank_irq);
DECLARE_WRITE_LINE_MEMBER(vblank_irq);
void draw_sprites( bitmap_ind16 &bitmap, const rectangle &cliprect );
required_device<cpu_device> m_maincpu;
required_device<gfxdecode_device> m_gfxdecode;

View File

@ -21,6 +21,7 @@ public:
m_spriteram_2(*this, "spriteram_2"),
m_snd_sharedram(*this, "snd_sharedram"),
m_maincpu(*this, "maincpu"),
m_cpu1(*this, "cpu1"),
m_vlm(*this, "vlm"),
m_filter1(*this, "filter1"),
m_filter2(*this, "filter2"),
@ -47,6 +48,7 @@ public:
/* devices */
required_device<cpu_device> m_maincpu;
required_device<cpu_device> m_cpu1;
required_device<vlm5030_device> m_vlm;
required_device<filter_rc_device> m_filter1;
required_device<filter_rc_device> m_filter2;
@ -73,8 +75,7 @@ public:
virtual void video_start() override;
DECLARE_PALETTE_INIT(ddribble);
uint32_t screen_update_ddribble(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
INTERRUPT_GEN_MEMBER(ddribble_interrupt_0);
INTERRUPT_GEN_MEMBER(ddribble_interrupt_1);
DECLARE_WRITE_LINE_MEMBER(vblank_irq);
void draw_sprites( bitmap_ind16 &bitmap, const rectangle &cliprect, uint8_t* source, int lenght, int gfxset, int flipscreen );
void ddribble(machine_config &config);
void cpu0_map(address_map &map);

View File

@ -65,8 +65,7 @@ public:
virtual void video_start() override;
DECLARE_PALETTE_INIT(gyruss);
uint32_t screen_update_gyruss(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
INTERRUPT_GEN_MEMBER(master_vblank_irq);
INTERRUPT_GEN_MEMBER(slave_vblank_irq);
DECLARE_WRITE_LINE_MEMBER(vblank_irq);
void draw_sprites( bitmap_ind16 &bitmap, const rectangle &cliprect );
void filter_w(address_space &space, int chip, int data );
void gyruss(machine_config &config);

View File

@ -55,7 +55,7 @@ public:
TILE_GET_INFO_MEMBER(get_bg_tile_info);
TILE_GET_INFO_MEMBER(roadf_get_bg_tile_info);
uint32_t screen_update(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
INTERRUPT_GEN_MEMBER(vblank_irq);
DECLARE_WRITE_LINE_MEMBER(vblank_irq);
void draw_sprites(bitmap_ind16 &bitmap, const rectangle &cliprect);
void hyperspt(machine_config &config);
void roadf(machine_config &config);

View File

@ -53,7 +53,7 @@ public:
virtual void video_start() override;
DECLARE_PALETTE_INIT(jackal);
uint32_t screen_update_jackal(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
INTERRUPT_GEN_MEMBER(jackal_interrupt);
DECLARE_WRITE_LINE_MEMBER(vblank_irq);
void jackal_mark_tile_dirty( int offset );
void draw_background( screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect );
void draw_sprites_region( bitmap_ind16 &bitmap, const rectangle &cliprect, const uint8_t *sram, int length, int bank );

View File

@ -61,7 +61,7 @@ public:
virtual void video_start() override;
DECLARE_PALETTE_INIT(megazone);
uint32_t screen_update_megazone(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
INTERRUPT_GEN_MEMBER(vblank_irq);
DECLARE_WRITE_LINE_MEMBER(vblank_irq);
void megazone(machine_config &config);
void megazone_i8039_io_map(address_map &map);
void megazone_i8039_map(address_map &map);

View File

@ -50,7 +50,7 @@ public:
virtual void video_start() override;
DECLARE_PALETTE_INIT(mikie);
uint32_t screen_update_mikie(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
INTERRUPT_GEN_MEMBER(vblank_irq);
DECLARE_WRITE_LINE_MEMBER(vblank_irq);
void draw_sprites(bitmap_ind16 &bitmap, const rectangle &cliprect);
void mikie(machine_config &config);
void mikie_map(address_map &map);

View File

@ -53,10 +53,11 @@ public:
required_device<gfxdecode_device> m_gfxdecode;
required_device<palette_device> m_palette;
uint8_t m_main_irq_mask;
bool m_main_irq_mask;
DECLARE_WRITE8_MEMBER(rallyx_interrupt_vector_w);
DECLARE_WRITE_LINE_MEMBER(bang_w);
DECLARE_WRITE_LINE_MEMBER(irq_mask_w);
DECLARE_WRITE_LINE_MEMBER(nmi_mask_w);
DECLARE_WRITE_LINE_MEMBER(sound_on_w);
DECLARE_WRITE_LINE_MEMBER(flip_screen_w);
DECLARE_WRITE_LINE_MEMBER(led_0_w);
@ -83,8 +84,8 @@ public:
uint32_t screen_update_rallyx(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
uint32_t screen_update_jungler(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
uint32_t screen_update_locomotn(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
INTERRUPT_GEN_MEMBER(rallyx_vblank_irq);
INTERRUPT_GEN_MEMBER(jungler_vblank_irq);
DECLARE_WRITE_LINE_MEMBER(rallyx_vblank_irq);
DECLARE_WRITE_LINE_MEMBER(jungler_vblank_irq);
inline void rallyx_get_tile_info( tile_data &tileinfo, int tile_index, int ram_offs);
inline void locomotn_get_tile_info(tile_data &tileinfo,int tile_index,int ram_offs);
void calculate_star_field( );

View File

@ -58,7 +58,7 @@ public:
virtual void video_start() override;
DECLARE_PALETTE_INIT(sbasketb);
uint32_t screen_update_sbasketb(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
INTERRUPT_GEN_MEMBER(vblank_irq);
DECLARE_WRITE_LINE_MEMBER(vblank_irq);
void draw_sprites( bitmap_ind16 &bitmap, const rectangle &cliprect );
void sbasketb(machine_config &config);
void sbasketbu(machine_config &config);

View File

@ -44,7 +44,7 @@ public:
TILE_GET_INFO_MEMBER(get_bg_tile_info);
INTERRUPT_GEN_MEMBER(interrupt);
DECLARE_WRITE_LINE_MEMBER(vblank_irq);
virtual void video_start() override;
DECLARE_PALETTE_INIT(scotrsht);

View File

@ -41,7 +41,7 @@ public:
DECLARE_MACHINE_START(tutankhm);
DECLARE_MACHINE_RESET(tutankhm);
uint32_t screen_update_tutankhm(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
INTERRUPT_GEN_MEMBER(tutankhm_interrupt);
DECLARE_WRITE_LINE_MEMBER(vblank_irq);
void tutankhm(machine_config &config);
void main_map(address_map &map);
};