diff options
author | AJR <ajrhacker@users.noreply.github.com> | 2018-05-26 12:01:56 -0400 |
---|---|---|
committer | AJR <ajrhacker@users.noreply.github.com> | 2018-05-26 12:01:56 -0400 |
commit | 3b1f444328fb759babc6635d0ed8379f4aecbf29 (patch) | |
tree | f8ac4eb5fc43f7f64bb9160994cdb963d30a6003 /src/mame/drivers | |
parent | 11e613b1cdc498dfd7b5d095ba118c1ba299bef7 (diff) |
atarist.cpp: Use device finder for floppies (nw)
blitz68k.cpp: Of course this has to be optional (nw)
Diffstat (limited to 'src/mame/drivers')
-rw-r--r-- | src/mame/drivers/atarist.cpp | 17 | ||||
-rw-r--r-- | src/mame/drivers/blitz68k.cpp | 2 |
2 files changed, 5 insertions, 14 deletions
diff --git a/src/mame/drivers/atarist.cpp b/src/mame/drivers/atarist.cpp index 7c57703c956..b18f91a298c 100644 --- a/src/mame/drivers/atarist.cpp +++ b/src/mame/drivers/atarist.cpp @@ -1701,9 +1701,9 @@ WRITE8_MEMBER( st_state::psg_pa_w ) // drive select floppy_image_device *floppy = nullptr; if (!BIT(data, 1)) - floppy = floppy_devices[0]; + floppy = m_floppy[0]->get_device(); else if(!BIT(data, 2)) - floppy = floppy_devices[1]; + floppy = m_floppy[1]->get_device(); // side select if(floppy) @@ -1745,9 +1745,9 @@ WRITE8_MEMBER( stbook_state::psg_pa_w ) // drive select floppy_image_device *floppy = nullptr; if (!BIT(data, 1)) - floppy = floppy_devices[0]; + floppy = m_floppy[0]->get_device(); else if(!BIT(data, 2)) - floppy = floppy_devices[1]; + floppy = m_floppy[1]->get_device(); // side select if(floppy) @@ -1908,15 +1908,6 @@ void st_state::machine_start() // register for state saving state_save(); - static const char *names[] = { WD1772_TAG ":0", WD1772_TAG ":1" }; - for(int i=0; i != 2; i++) { - floppy_connector *con = machine().device<floppy_connector>(names[i]); - if(con) - floppy_devices[i] = con->get_device(); - else - floppy_devices[i] = nullptr; - } - /// TODO: get callbacks to trigger these. m_mfp->i0_w(1); m_mfp->i5_w(1); diff --git a/src/mame/drivers/blitz68k.cpp b/src/mame/drivers/blitz68k.cpp index 1cdbc368d36..53bcf67b13e 100644 --- a/src/mame/drivers/blitz68k.cpp +++ b/src/mame/drivers/blitz68k.cpp @@ -210,7 +210,7 @@ protected: optional_shared_ptr<uint16_t> m_leds2; required_device<cpu_device> m_maincpu; required_device<palette_device> m_palette; - required_device<mc6845_device> m_crtc; + optional_device<mc6845_device> m_crtc; output_finder<17> m_led; }; |