From 3998824713dbbee8cc044e778c821848d7b0ed86 Mon Sep 17 00:00:00 2001 From: Michael Zapf Date: Fri, 13 Jan 2017 21:17:54 +0100 Subject: [PATCH] floppy: Added TODO comments; revert stp_w ignore on spin-up until further evidence --- src/devices/imagedev/floppy.cpp | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/src/devices/imagedev/floppy.cpp b/src/devices/imagedev/floppy.cpp index cdbffe81b36..69413ae57cf 100644 --- a/src/devices/imagedev/floppy.cpp +++ b/src/devices/imagedev/floppy.cpp @@ -632,7 +632,9 @@ bool floppy_image_device::twosid_r() void floppy_image_device::stp_w(int state) { // Before spin-up is done, ignore step pulses - if (ready_counter > 0) return; + // TODO: There are reports about drives supporting step operation with + // stopped spindle. Need to check that on real drives. + // if (ready_counter > 0) return; if ( stp != state ) { stp = state; @@ -755,8 +757,14 @@ attotime floppy_image_device::get_next_index_time(std::vector &buf, in attotime floppy_image_device::get_next_transition(const attotime &from_when) { + if(!image || mon) + return attotime::never; + // If the drive is still spinning up, pretend that no transitions will come - if(!image || mon || ready_counter > 0) + // TODO: Implement a proper spin-up ramp for transition times, also in order + // to cover potential copy protection measures that have direct device + // access (mz) + if (ready_counter > 0) return attotime::never; std::vector &buf = image->get_buffer(cyl, ss, subcyl);