diff options
Diffstat (limited to 'src/mame/drivers/battlane.cpp')
-rw-r--r-- | src/mame/drivers/battlane.cpp | 27 |
1 files changed, 14 insertions, 13 deletions
diff --git a/src/mame/drivers/battlane.cpp b/src/mame/drivers/battlane.cpp index 650572e8f3f..10adf5a396a 100644 --- a/src/mame/drivers/battlane.cpp +++ b/src/mame/drivers/battlane.cpp @@ -100,19 +100,20 @@ INTERRUPT_GEN_MEMBER(battlane_state::battlane_cpu1_interrupt) * *************************************/ -ADDRESS_MAP_START(battlane_state::battlane_map) - AM_RANGE(0x0000, 0x0fff) AM_RAM AM_SHARE("share1") - AM_RANGE(0x1000, 0x17ff) AM_RAM_WRITE(battlane_tileram_w) AM_SHARE("tileram") - AM_RANGE(0x1800, 0x18ff) AM_RAM_WRITE(battlane_spriteram_w) AM_SHARE("spriteram") - AM_RANGE(0x1c00, 0x1c00) AM_READ_PORT("P1") AM_WRITE(battlane_video_ctrl_w) - AM_RANGE(0x1c01, 0x1c01) AM_READ_PORT("P2") AM_WRITE(battlane_scrollx_w) - AM_RANGE(0x1c02, 0x1c02) AM_READ_PORT("DSW1") AM_WRITE(battlane_scrolly_w) - AM_RANGE(0x1c03, 0x1c03) AM_READ_PORT("DSW2") AM_WRITE(battlane_cpu_command_w) - AM_RANGE(0x1c04, 0x1c05) AM_DEVREADWRITE("ymsnd", ym3526_device, read, write) - AM_RANGE(0x1e00, 0x1e3f) AM_WRITE(battlane_palette_w) - AM_RANGE(0x2000, 0x3fff) AM_RAM_WRITE(battlane_bitmap_w) AM_SHARE("share4") - AM_RANGE(0x4000, 0xffff) AM_ROM -ADDRESS_MAP_END +void battlane_state::battlane_map(address_map &map) +{ + map(0x0000, 0x0fff).ram().share("share1"); + map(0x1000, 0x17ff).ram().w(this, FUNC(battlane_state::battlane_tileram_w)).share("tileram"); + map(0x1800, 0x18ff).ram().w(this, FUNC(battlane_state::battlane_spriteram_w)).share("spriteram"); + map(0x1c00, 0x1c00).portr("P1").w(this, FUNC(battlane_state::battlane_video_ctrl_w)); + map(0x1c01, 0x1c01).portr("P2").w(this, FUNC(battlane_state::battlane_scrollx_w)); + map(0x1c02, 0x1c02).portr("DSW1").w(this, FUNC(battlane_state::battlane_scrolly_w)); + map(0x1c03, 0x1c03).portr("DSW2").w(this, FUNC(battlane_state::battlane_cpu_command_w)); + map(0x1c04, 0x1c05).rw("ymsnd", FUNC(ym3526_device::read), FUNC(ym3526_device::write)); + map(0x1e00, 0x1e3f).w(this, FUNC(battlane_state::battlane_palette_w)); + map(0x2000, 0x3fff).ram().w(this, FUNC(battlane_state::battlane_bitmap_w)).share("share4"); + map(0x4000, 0xffff).rom(); +} /************************************* |