summaryrefslogtreecommitdiffstatshomepage
path: root/src/mame/drivers/tim100.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/mame/drivers/tim100.cpp')
-rw-r--r--src/mame/drivers/tim100.cpp34
1 files changed, 18 insertions, 16 deletions
diff --git a/src/mame/drivers/tim100.cpp b/src/mame/drivers/tim100.cpp
index 2ad54a9ecf0..e7cfe6a057f 100644
--- a/src/mame/drivers/tim100.cpp
+++ b/src/mame/drivers/tim100.cpp
@@ -51,22 +51,24 @@ private:
required_device<i8275_device> m_crtc;
};
-ADDRESS_MAP_START(tim100_state::tim100_mem)
- ADDRESS_MAP_UNMAP_HIGH
- AM_RANGE(0x0000, 0x1fff) AM_ROM // 2764 at U16
- AM_RANGE(0x2000, 0x27ff) AM_RAM AM_SHARE("videoram") // 2KB static ram CDM6116A at U15
- AM_RANGE(0x6000, 0x6000) AM_DEVREADWRITE("uart_u17", i8251_device, data_r, data_w)
- AM_RANGE(0x6001, 0x6001) AM_DEVREADWRITE("uart_u17", i8251_device, status_r, control_w)
- AM_RANGE(0x8000, 0x8000) AM_DEVREADWRITE("uart_u18", i8251_device, data_r, data_w)
- AM_RANGE(0x8001, 0x8001) AM_DEVREADWRITE("uart_u18", i8251_device, status_r, control_w)
- AM_RANGE(0xa000, 0xa000) AM_WRITENOP // continuously writes 00 here
- AM_RANGE(0xc000, 0xc001) AM_DEVREADWRITE("crtc", i8275_device, read, write) // i8276
-ADDRESS_MAP_END
-
-ADDRESS_MAP_START(tim100_state::tim100_io)
- ADDRESS_MAP_UNMAP_HIGH
- ADDRESS_MAP_GLOBAL_MASK(0xff)
-ADDRESS_MAP_END
+void tim100_state::tim100_mem(address_map &map)
+{
+ map.unmap_value_high();
+ map(0x0000, 0x1fff).rom(); // 2764 at U16
+ map(0x2000, 0x27ff).ram().share("videoram"); // 2KB static ram CDM6116A at U15
+ map(0x6000, 0x6000).rw("uart_u17", FUNC(i8251_device::data_r), FUNC(i8251_device::data_w));
+ map(0x6001, 0x6001).rw("uart_u17", FUNC(i8251_device::status_r), FUNC(i8251_device::control_w));
+ map(0x8000, 0x8000).rw("uart_u18", FUNC(i8251_device::data_r), FUNC(i8251_device::data_w));
+ map(0x8001, 0x8001).rw("uart_u18", FUNC(i8251_device::status_r), FUNC(i8251_device::control_w));
+ map(0xa000, 0xa000).nopw(); // continuously writes 00 here
+ map(0xc000, 0xc001).rw(m_crtc, FUNC(i8275_device::read), FUNC(i8275_device::write)); // i8276
+}
+
+void tim100_state::tim100_io(address_map &map)
+{
+ map.unmap_value_high();
+ map.global_mask(0xff);
+}
/* Input ports */