summaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
author Olivier Galibert <galibert@pobox.com>2018-04-19 21:51:44 +0200
committer Olivier Galibert <galibert@pobox.com>2018-04-19 23:04:31 +0200
commitd207fca25023e5bed8498a4c55d41ae5eca9a72d (patch)
tree10284496c62f661b28b5fcf77aface38c0a1830e
parentc6c737de5933cef418e64198d7865d8c8f1cd775 (diff)
maps: Finish mame/etc (nw)
-rw-r--r--src/mame/etc/korgm1.cpp44
-rw-r--r--src/mame/etc/template_driver.cpp14
2 files changed, 31 insertions, 27 deletions
diff --git a/src/mame/etc/korgm1.cpp b/src/mame/etc/korgm1.cpp
index 0f5ddb73f6c..2cc318bf347 100644
--- a/src/mame/etc/korgm1.cpp
+++ b/src/mame/etc/korgm1.cpp
@@ -54,28 +54,30 @@ uint32_t korgm1_state::screen_update( screen_device &screen, bitmap_ind16 &bitma
return 0;
}
-ADDRESS_MAP_START(korgm1_state::korgm1_map)
- AM_RANGE(0x00000, 0x0ffff) AM_RAM // 64 KB
-// AM_RANGE(0x50000, 0x57fff) AM_RAM // memory card 32 KB
- AM_RANGE(0xe0000, 0xfffff) AM_ROM AM_REGION("ipl", 0)
-ADDRESS_MAP_END
-
-ADDRESS_MAP_START(korgm1_state::korgm1_io)
-// AM_RANGE(0x0000, 0x00ff) internal peripheral (?)
-// AM_RANGE(0x0100, 0x01ff) VDF 1 (MB87404)
-// AM_RANGE(0x0200, 0x02ff) VDF 2 (MB87404)
-// AM_RANGE(0x0500, 0x0503) MDE (MB87405)
-// AM_RANGE(0x0600, 0x0601) OPZ 1 (8-bit port)
-// AM_RANGE(0x0700, 0x0701) OPZ 2 (8-bit port)
-// AM_RANGE(0x0800, 0x0801) SCAN (8-bit port) (keyboard)
-// AM_RANGE(0x0900, 0x0900) ADC (M58990P, compatible with ADC0808; Joystick, "value" and After Touch routes here)
-// AM_RANGE(0x0a00, 0x0a07) PIO (CXD1095Q; LCD, LED and SW routes here; also controls ADC channel select and TG/VDF/MDE reset line)
-// AM_RANGE(0x0b00, 0x0b01) LCDC (8-bit port)
-// AM_RANGE(0x1000, 0x11ff) TG (MB87402)
-// AM_RANGE(0x2000, 0x23ff) SCSI
-// AM_RANGE(0x3000, 0x33ff) FDC
+void korgm1_state::korgm1_map(address_map &map)
+{
+ map(0x00000, 0x0ffff).ram(); // 64 KB
+// map(0x50000, 0x57fff).ram(); // memory card 32 KB
+ map(0xe0000, 0xfffff).rom().region("ipl", 0);
+}
+
+void korgm1_state::korgm1_io(address_map &map)
+{
+// map(0x0000, 0x00ff); internal peripheral (?)
+// map(0x0100, 0x01ff); VDF 1 (MB87404)
+// map(0x0200, 0x02ff); VDF 2 (MB87404)
+// map(0x0500, 0x0503); MDE (MB87405)
+// map(0x0600, 0x0601); OPZ 1 (8-bit port)
+// map(0x0700, 0x0701); OPZ 2 (8-bit port)
+// map(0x0800, 0x0801); SCAN (8-bit port) (keyboard)
+// map(0x0900, 0x0900); ADC (M58990P, compatible with ADC0808; Joystick, "value" and After Touch routes here)
+// map(0x0a00, 0x0a07); PIO (CXD1095Q; LCD, LED and SW routes here; also controls ADC channel select and TG/VDF/MDE reset line)
+// map(0x0b00, 0x0b01); LCDC (8-bit port)
+// map(0x1000, 0x11ff); TG (MB87402)
+// map(0x2000, 0x23ff); SCSI
+// map(0x3000, 0x33ff); FDC
// TG 2?
-ADDRESS_MAP_END
+}
static INPUT_PORTS_START( korgm1 )
/* dummy active high structure */
diff --git a/src/mame/etc/template_driver.cpp b/src/mame/etc/template_driver.cpp
index 9048e8a26d2..067e2f4d1e9 100644
--- a/src/mame/etc/template_driver.cpp
+++ b/src/mame/etc/template_driver.cpp
@@ -52,13 +52,15 @@ uint32_t xxx_state::screen_update( screen_device &screen, bitmap_ind16 &bitmap,
return 0;
}
-ADDRESS_MAP_START(xxx_state::xxx_map)
- AM_RANGE(0x0000, 0x7fff) AM_ROM
-ADDRESS_MAP_END
+void xxx_state::xxx_map(address_map &map)
+{
+ map(0x0000, 0x7fff).rom();
+}
-ADDRESS_MAP_START(xxx_state::xxx_io)
-// ADDRESS_MAP_GLOBAL_MASK(0xff)
-ADDRESS_MAP_END
+void xxx_state::xxx_io(address_map &map)
+{
+ map.global_mask(0xff);
+}
static INPUT_PORTS_START( xxx )
/* dummy active high structure */