diff options
author | 2018-03-13 07:36:43 +0100 | |
---|---|---|
committer | 2018-03-14 14:07:14 +0100 | |
commit | 115bb9936c5cd3faf955d7eb1e251a94e4744b7b (patch) | |
tree | f0230f547f6c750f9974c61479eef28cbe4ad571 /src/mame/drivers/bigstrkb.cpp | |
parent | f155992daab88ad024cec995428a67108218b51d (diff) |
Address maps macros removal, pass 1 [O. Galibert]
Diffstat (limited to 'src/mame/drivers/bigstrkb.cpp')
-rw-r--r-- | src/mame/drivers/bigstrkb.cpp | 67 |
1 files changed, 34 insertions, 33 deletions
diff --git a/src/mame/drivers/bigstrkb.cpp b/src/mame/drivers/bigstrkb.cpp index 95e020a292e..65c4580b291 100644 --- a/src/mame/drivers/bigstrkb.cpp +++ b/src/mame/drivers/bigstrkb.cpp @@ -39,50 +39,51 @@ lev 7 : 0x7c : 0000 05be - xxx /* some regions might be too large */ -ADDRESS_MAP_START(bigstrkb_state::bigstrkb_map) - AM_RANGE(0x000000, 0x07ffff) AM_ROM +void bigstrkb_state::bigstrkb_map(address_map &map) +{ + map(0x000000, 0x07ffff).rom(); // AM_RANGE(0x0c0000, 0x0cffff) AM_READWRITE_LEGACY(megasys1_vregs_C_r, megasys1_vregs_C_w) AM_SHARE("megasys1_vregs") - AM_RANGE(0x0C2004, 0x0C2005) AM_WRITENOP - AM_RANGE(0x0C200C, 0x0C200d) AM_WRITENOP - AM_RANGE(0x0C2104, 0x0C2105) AM_WRITENOP - AM_RANGE(0x0C2108, 0x0C2109) AM_WRITENOP - AM_RANGE(0x0C2200, 0x0C2201) AM_WRITENOP - AM_RANGE(0x0C2208, 0x0C2209) AM_WRITENOP - AM_RANGE(0x0c2308, 0x0c2309) AM_WRITENOP // bit 0 of DSW1 (flip screen) - use vregs + map(0x0C2004, 0x0C2005).nopw(); + map(0x0C200C, 0x0C200d).nopw(); + map(0x0C2104, 0x0C2105).nopw(); + map(0x0C2108, 0x0C2109).nopw(); + map(0x0C2200, 0x0C2201).nopw(); + map(0x0C2208, 0x0C2209).nopw(); + map(0x0c2308, 0x0c2309).nopw(); // bit 0 of DSW1 (flip screen) - use vregs - AM_RANGE(0x0D0000, 0x0dffff) AM_RAM // 0xd2000 - 0xd3fff? 0xd8000? + map(0x0D0000, 0x0dffff).ram(); // 0xd2000 - 0xd3fff? 0xd8000? - AM_RANGE(0x0e0000, 0x0e3fff) AM_RAM_WRITE(videoram2_w) AM_SHARE("videoram2") - AM_RANGE(0x0e8000, 0x0ebfff) AM_RAM_WRITE(videoram3_w) AM_SHARE("videoram3") - AM_RANGE(0x0ec000, 0x0effff) AM_RAM_WRITE(videoram_w) AM_SHARE("videoram") + map(0x0e0000, 0x0e3fff).ram().w(this, FUNC(bigstrkb_state::videoram2_w)).share("videoram2"); + map(0x0e8000, 0x0ebfff).ram().w(this, FUNC(bigstrkb_state::videoram3_w)).share("videoram3"); + map(0x0ec000, 0x0effff).ram().w(this, FUNC(bigstrkb_state::videoram_w)).share("videoram"); - AM_RANGE(0x0f0000, 0x0f7fff) AM_RAM - AM_RANGE(0x0f8000, 0x0f87ff) AM_RAM_DEVWRITE("palette", palette_device, write16) AM_SHARE("palette") - AM_RANGE(0x0f8800, 0x0fffff) AM_RAM + map(0x0f0000, 0x0f7fff).ram(); + map(0x0f8000, 0x0f87ff).ram().w(m_palette, FUNC(palette_device::write16)).share("palette"); + map(0x0f8800, 0x0fffff).ram(); - AM_RANGE(0x1f0000, 0x1f7fff) AM_RAM - AM_RANGE(0x1f8000, 0x1f87ff) AM_RAM AM_SHARE("spriteram") - AM_RANGE(0x1f8800, 0x1fffff) AM_RAM + map(0x1f0000, 0x1f7fff).ram(); + map(0x1f8000, 0x1f87ff).ram().share("spriteram"); + map(0x1f8800, 0x1fffff).ram(); - AM_RANGE(0x700000, 0x700001) AM_READ_PORT("DSW0") - AM_RANGE(0x700002, 0x700003) AM_READ_PORT("DSW1") - AM_RANGE(0x700004, 0x700005) AM_READ_PORT("SYSTEM") - AM_RANGE(0x70000a, 0x70000b) AM_READ_PORT("P2") - AM_RANGE(0x70000c, 0x70000d) AM_READ_PORT("P1") - AM_RANGE(0x700020, 0x700027) AM_WRITEONLY AM_SHARE("vidreg1") - AM_RANGE(0x700030, 0x700037) AM_WRITEONLY AM_SHARE("vidreg2") + map(0x700000, 0x700001).portr("DSW0"); + map(0x700002, 0x700003).portr("DSW1"); + map(0x700004, 0x700005).portr("SYSTEM"); + map(0x70000a, 0x70000b).portr("P2"); + map(0x70000c, 0x70000d).portr("P1"); + map(0x700020, 0x700027).writeonly().share("vidreg1"); + map(0x700030, 0x700037).writeonly().share("vidreg2"); - AM_RANGE(0xB00000, 0xB00001) AM_WRITENOP + map(0xB00000, 0xB00001).nopw(); - AM_RANGE(0xE00000, 0xE00001) AM_DEVREADWRITE8("oki1", okim6295_device, read, write, 0x00ff) - AM_RANGE(0xE00002, 0xE00003) AM_DEVREADWRITE8("oki2", okim6295_device, read, write, 0x00ff) + map(0xe00001, 0xe00001).rw("oki1", FUNC(okim6295_device::read), FUNC(okim6295_device::write)); + map(0xe00003, 0xe00003).rw("oki2", FUNC(okim6295_device::read), FUNC(okim6295_device::write)); - AM_RANGE(0xE00008, 0xE00009) AM_WRITENOP - AM_RANGE(0xE0000c, 0xE0000d) AM_WRITENOP + map(0xE00008, 0xE00009).nopw(); + map(0xE0000c, 0xE0000d).nopw(); - AM_RANGE(0xF00000, 0xFFFFFF) AM_RAM -ADDRESS_MAP_END + map(0xF00000, 0xFFFFFF).ram(); +} #define BIGSTRKB_PLAYER_INPUT( player, start ) \ PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_JOYSTICK_UP ) PORT_PLAYER(player) PORT_8WAY \ |