From 0015f48a7527ebef1e5c3439abf0fdce2e6b5b50 Mon Sep 17 00:00:00 2001 From: AJR Date: Sun, 3 Jun 2018 14:16:22 -0400 Subject: [PATCH] svision.cpp: Use MCFG_SCREEN_VBLANK_CALLBACK instead of MCFG_DEVICE_VBLANK_INT, darn it (nw) --- src/mame/drivers/svision.cpp | 9 ++++++--- src/mame/includes/svision.h | 2 +- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/src/mame/drivers/svision.cpp b/src/mame/drivers/svision.cpp index a8b15a0a3f5..2aa5122d22d 100644 --- a/src/mame/drivers/svision.cpp +++ b/src/mame/drivers/svision.cpp @@ -422,10 +422,13 @@ uint32_t svision_state::screen_update_tvlink(screen_device &screen, bitmap_rgb32 return 0; } -INTERRUPT_GEN_MEMBER(svision_state::svision_frame_int) +WRITE_LINE_MEMBER(svision_state::frame_int_w) { + if (!state) + return; + if (BIT(m_reg[BANK], 0)) - device.execute().pulse_input_line(INPUT_LINE_NMI, attotime::zero); + m_maincpu->pulse_input_line(INPUT_LINE_NMI, attotime::zero); m_sound->sound_decrement(); } @@ -519,7 +522,6 @@ MACHINE_CONFIG_START(svision_state::svision) MCFG_DEVICE_ADD(m_maincpu, M65C02, 4000000) MCFG_DEVICE_PROGRAM_MAP(svision_mem) - MCFG_DEVICE_VBLANK_INT_DRIVER(m_screen, svision_state, svision_frame_int) MCFG_SCREEN_ADD(m_screen, LCD) MCFG_SCREEN_REFRESH_RATE(61) @@ -527,6 +529,7 @@ MACHINE_CONFIG_START(svision_state::svision) MCFG_SCREEN_VISIBLE_AREA(3+0, 3+160-1, 0, 160-1) MCFG_SCREEN_UPDATE_DRIVER(svision_state, screen_update_svision) MCFG_SCREEN_PALETTE(m_palette) + MCFG_SCREEN_VBLANK_CALLBACK(WRITELINE(*this, svision_state, frame_int_w)) MCFG_PALETTE_ADD(m_palette, ARRAY_LENGTH(svision_palette) * 3) MCFG_PALETTE_INIT_OWNER(svision_state, svision ) diff --git a/src/mame/includes/svision.h b/src/mame/includes/svision.h index 386ac2ff71d..22f61f4d243 100644 --- a/src/mame/includes/svision.h +++ b/src/mame/includes/svision.h @@ -62,7 +62,7 @@ public: void init_svision(); uint32_t screen_update_svision(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect); uint32_t screen_update_tvlink(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect); - INTERRUPT_GEN_MEMBER(svision_frame_int); + DECLARE_WRITE_LINE_MEMBER(frame_int_w); DECLARE_DEVICE_IMAGE_LOAD_MEMBER(svision_cart); void svisionp(machine_config &config);