diff options
author | AJR <ajrhacker@users.noreply.github.com> | 2017-06-21 23:14:50 -0400 |
---|---|---|
committer | AJR <ajrhacker@users.noreply.github.com> | 2017-06-21 23:14:50 -0400 |
commit | 164ada70857eb09389c1784900c805d76b031105 (patch) | |
tree | 2cd5a86541eab6a30fcb79576f3ac86ee8bc1730 | |
parent | 14c3a7fbd339197e66eda6ac7a3b52462ae6c9e8 (diff) |
snk68.cpp: Soundlatch modernization (nw)
-rw-r--r-- | src/mame/drivers/snk68.cpp | 14 | ||||
-rw-r--r-- | src/mame/includes/snk68.h | 1 |
2 files changed, 3 insertions, 12 deletions
diff --git a/src/mame/drivers/snk68.cpp b/src/mame/drivers/snk68.cpp index 2dc6ed055f9..19a1177b527 100644 --- a/src/mame/drivers/snk68.cpp +++ b/src/mame/drivers/snk68.cpp @@ -96,22 +96,13 @@ WRITE16_MEMBER(snk68_state::protection_w) } } -WRITE16_MEMBER(snk68_state::sound_w) -{ - if (ACCESSING_BITS_8_15) - { - m_soundlatch->write(space, 0, data >> 8); - m_soundcpu->set_input_line(INPUT_LINE_NMI, PULSE_LINE); - } -} - /*******************************************************************************/ static ADDRESS_MAP_START( pow_map, AS_PROGRAM, 16, snk68_state ) AM_RANGE(0x000000, 0x03ffff) AM_ROM AM_RANGE(0x040000, 0x043fff) AM_RAM AM_RANGE(0x080000, 0x080001) AM_READ(control_1_r) - AM_RANGE(0x080000, 0x080001) AM_WRITE(sound_w) + AM_RANGE(0x080000, 0x080001) AM_DEVWRITE8("soundlatch", generic_latch_8_device, write, 0xff00) AM_RANGE(0x0c0000, 0x0c0001) AM_READ_PORT("SYSTEM") AM_RANGE(0x0c0000, 0x0c0001) AM_WRITE(pow_flipscreen_w) // + char bank AM_RANGE(0x0e0000, 0x0e0001) AM_READNOP /* Watchdog or IRQ ack */ @@ -128,7 +119,7 @@ static ADDRESS_MAP_START( searchar_map, AS_PROGRAM, 16, snk68_state ) AM_RANGE(0x000000, 0x03ffff) AM_ROM AM_RANGE(0x040000, 0x043fff) AM_RAM AM_RANGE(0x080000, 0x080005) AM_READ(protcontrols_r) /* Player 1 & 2 */ - AM_RANGE(0x080000, 0x080001) AM_WRITE(sound_w) + AM_RANGE(0x080000, 0x080001) AM_DEVWRITE8("soundlatch", generic_latch_8_device, write, 0xff00) AM_RANGE(0x080006, 0x080007) AM_WRITE(protection_w) /* top byte unknown, bottom is protection in ikari3 and streetsm */ AM_RANGE(0x0c0000, 0x0c0001) AM_WRITE(searchar_flipscreen_w) AM_RANGE(0x0c0000, 0x0c0001) AM_READ(rotary_1_r) /* Player 1 rotary */ @@ -623,6 +614,7 @@ static MACHINE_CONFIG_START( pow ) MCFG_SPEAKER_STANDARD_MONO("mono") MCFG_GENERIC_LATCH_8_ADD("soundlatch") + MCFG_GENERIC_LATCH_DATA_PENDING_CB(INPUTLINE("soundcpu", INPUT_LINE_NMI)) MCFG_GENERIC_LATCH_8_ADD("soundlatch2") MCFG_SOUND_ADD("ymsnd", YM3812, XTAL_8MHz/2) /* verified on pcb */ diff --git a/src/mame/includes/snk68.h b/src/mame/includes/snk68.h index cd68fe12fe6..8cf39f49e70 100644 --- a/src/mame/includes/snk68.h +++ b/src/mame/includes/snk68.h @@ -39,7 +39,6 @@ public: uint32_t m_fg_tile_offset; // common - DECLARE_WRITE16_MEMBER(sound_w); DECLARE_WRITE8_MEMBER(D7759_write_port_0_w); DECLARE_WRITE8_MEMBER(D7759_upd_reset_w); |