diff options
Diffstat (limited to 'src/mame/drivers/splash.cpp')
-rw-r--r-- | src/mame/drivers/splash.cpp | 21 |
1 files changed, 10 insertions, 11 deletions
diff --git a/src/mame/drivers/splash.cpp b/src/mame/drivers/splash.cpp index f56003817b1..852d40b9d09 100644 --- a/src/mame/drivers/splash.cpp +++ b/src/mame/drivers/splash.cpp @@ -48,7 +48,6 @@ More notes about Funny Strip protection issues at the bottom of source file (DRI #include "cpu/z80/z80.h" #include "cpu/m68000/m68000.h" -#include "machine/74259.h" #include "sound/2203intf.h" #include "sound/3812intf.h" #include "screen.h" @@ -74,14 +73,14 @@ WRITE_LINE_MEMBER(splash_state::coin2_counter_w) machine().bookkeeping().coin_counter_w(1, state); } -static ADDRESS_MAP_START( splash_map, AS_PROGRAM, 16, splash_state ) +ADDRESS_MAP_START(splash_state::splash_map) AM_RANGE(0x000000, 0x3fffff) AM_ROM /* ROM */ AM_RANGE(0x800000, 0x83ffff) AM_RAM AM_SHARE("pixelram") /* Pixel Layer */ AM_RANGE(0x840000, 0x840001) AM_READ_PORT("DSW1") AM_RANGE(0x840002, 0x840003) AM_READ_PORT("DSW2") AM_RANGE(0x840004, 0x840005) AM_READ_PORT("P1") AM_RANGE(0x840006, 0x840007) AM_READ_PORT("P2") - AM_RANGE(0x84000a, 0x84000b) AM_SELECT(0x000070) AM_DEVWRITE8_MOD("outlatch", ls259_device, write_d0, rshift<3>, 0xff00) + ;map(0x84000a, 0x84000b).select(0x000070).lw8("outlatch_w", [this](address_space &space, offs_t offset, u8 data, u8 mem_mask){ m_outlatch->write_d0(space, offset >> 3, data, mem_mask); }).umask16(0xff00); AM_RANGE(0x84000e, 0x84000f) AM_DEVWRITE8("soundlatch", generic_latch_8_device, write, 0x00ff) AM_RANGE(0x880000, 0x8817ff) AM_RAM_WRITE(vram_w) AM_SHARE("videoram") /* Video RAM */ AM_RANGE(0x881800, 0x881803) AM_RAM AM_SHARE("vregs") /* Scroll registers */ @@ -107,7 +106,7 @@ WRITE_LINE_MEMBER(splash_state::splash_msm5205_int) m_adpcm_data = (m_adpcm_data << 4) & 0xf0; } -static ADDRESS_MAP_START( splash_sound_map, AS_PROGRAM, 8, splash_state ) +ADDRESS_MAP_START(splash_state::splash_sound_map) AM_RANGE(0x0000, 0xd7ff) AM_ROM /* ROM */ AM_RANGE(0xd800, 0xd800) AM_WRITE(splash_adpcm_data_w) /* ADPCM data for the MSM5205 chip */ AM_RANGE(0xe000, 0xe000) AM_WRITE(splash_adpcm_control_w) @@ -150,7 +149,7 @@ WRITE_LINE_MEMBER(splash_state::ym_irq) roldfrog_update_irq(); } -static ADDRESS_MAP_START( roldfrog_map, AS_PROGRAM, 16, splash_state ) +ADDRESS_MAP_START(splash_state::roldfrog_map) AM_RANGE(0x000000, 0x3fffff) AM_ROM /* ROM */ AM_RANGE(0x400000, 0x407fff) AM_ROM AM_SHARE("protdata") /* Protection Data */ AM_RANGE(0x408000, 0x4087ff) AM_RAM /* Extra Ram */ @@ -159,7 +158,7 @@ static ADDRESS_MAP_START( roldfrog_map, AS_PROGRAM, 16, splash_state ) AM_RANGE(0x840002, 0x840003) AM_READ_PORT("DSW2") AM_RANGE(0x840004, 0x840005) AM_READ_PORT("P1") AM_RANGE(0x840006, 0x840007) AM_READ_PORT("P2") - AM_RANGE(0x84000a, 0x84000b) AM_SELECT(0x000070) AM_DEVWRITE8_MOD("outlatch", ls259_device, write_d0, rshift<3>, 0xff00) + ;map(0x84000a, 0x84000b).select(0x000070).lw8("outlatch_w", [this](address_space &space, offs_t offset, u8 data, u8 mem_mask){ m_outlatch->write_d0(space, offset >> 3, data, mem_mask); }).umask16(0xff00); AM_RANGE(0x84000e, 0x84000f) AM_DEVWRITE8("soundlatch", generic_latch_8_device, write, 0x00ff) AM_RANGE(0x880000, 0x8817ff) AM_RAM_WRITE(vram_w) AM_SHARE("videoram") /* Video RAM */ AM_RANGE(0x881800, 0x881803) AM_RAM AM_SHARE("vregs") /* Scroll registers */ @@ -171,7 +170,7 @@ static ADDRESS_MAP_START( roldfrog_map, AS_PROGRAM, 16, splash_state ) AM_RANGE(0xffc000, 0xffffff) AM_RAM /* Work RAM */ ADDRESS_MAP_END -static ADDRESS_MAP_START( roldfrog_sound_map, AS_PROGRAM, 8, splash_state ) +ADDRESS_MAP_START(splash_state::roldfrog_sound_map) AM_RANGE(0x0000, 0x6fff) AM_ROM AM_RANGE(0x7000, 0x7fff) AM_RAM AM_RANGE(0x8000, 0xffff) AM_ROM AM_ROMBANK("sound_bank") @@ -183,7 +182,7 @@ READ8_MEMBER(splash_state::roldfrog_unk_r) return 0xff; } -static ADDRESS_MAP_START( roldfrog_sound_io_map, AS_IO, 8, splash_state ) +ADDRESS_MAP_START(splash_state::roldfrog_sound_io_map) ADDRESS_MAP_GLOBAL_MASK(0xff) AM_RANGE(0x10, 0x11) AM_DEVREADWRITE("ymsnd", ym2203_device, read, write) AM_RANGE(0x31, 0x31) AM_WRITE(sound_bank_w) @@ -212,7 +211,7 @@ WRITE8_MEMBER(funystrp_state::eeprom_w) m_eeprom->clk_write(BIT(data, 5)); } -static ADDRESS_MAP_START( funystrp_map, AS_PROGRAM, 16, funystrp_state ) +ADDRESS_MAP_START(funystrp_state::funystrp_map) AM_RANGE(0x000000, 0x07ffff) AM_ROM /* ROM */ AM_RANGE(0x100000, 0x1fffff) AM_RAM /* protection? RAM */ AM_RANGE(0x800000, 0x83ffff) AM_RAM AM_SHARE("pixelram") /* Pixel Layer */ @@ -231,7 +230,7 @@ static ADDRESS_MAP_START( funystrp_map, AS_PROGRAM, 16, funystrp_state ) AM_RANGE(0xfe0000, 0xfeffff) AM_RAM AM_MIRROR(0x10000) /* there's fe0000 <-> ff0000 compare */ /* Work RAM */ ADDRESS_MAP_END -static ADDRESS_MAP_START( funystrp_sound_map, AS_PROGRAM, 8, splash_state ) +ADDRESS_MAP_START(splash_state::funystrp_sound_map) AM_RANGE(0x0000, 0x6fff) AM_ROM AM_RANGE(0x7000, 0x7fff) AM_RAM AM_RANGE(0x8000, 0xffff) AM_ROM AM_ROMBANK("sound_bank") @@ -266,7 +265,7 @@ WRITE8_MEMBER(funystrp_state::msm2_data_w) m_msm_toggle2=0; } -static ADDRESS_MAP_START( funystrp_sound_io_map, AS_IO, 8, funystrp_state ) +ADDRESS_MAP_START(funystrp_state::funystrp_sound_io_map) ADDRESS_MAP_GLOBAL_MASK(0xff) AM_RANGE(0x00, 0x00) AM_WRITE(msm1_data_w) AM_RANGE(0x01, 0x01) AM_WRITE(msm2_data_w) |