mirror of
https://github.com/holub/mame
synced 2025-10-05 08:41:31 +03:00
upd765: Don't instantly finish the RECALIBRATE command
The RECALIBRATE command would instantly finish if the drive was already at track 0. This introduces a slight delay, so that code can execute between issuing the command and generating an interrupt. This fixes accessing the second drive on the psi98 driver.
This commit is contained in:
parent
daab86c830
commit
c86970de6c
@ -1473,13 +1473,20 @@ void upd765_family_device::seek_continue(floppy_info &fi)
|
||||
break;
|
||||
}
|
||||
if(done) {
|
||||
fi.st0 |= ST0_SE | fi.id;
|
||||
command_end(fi, false);
|
||||
fi.sub_state = SEEK_WAIT_DONE;
|
||||
// recalibrate takes some time, even if we are already at track 0
|
||||
fi.tm->adjust(attotime::from_nsec((fi.main_state == RECALIBRATE) ? 20000 : 0));
|
||||
return;
|
||||
}
|
||||
fi.sub_state = SEEK_MOVE;
|
||||
break;
|
||||
}
|
||||
|
||||
case SEEK_WAIT_DONE:
|
||||
fi.st0 |= ST0_SE | fi.id;
|
||||
command_end(fi, false);
|
||||
return;
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -223,6 +223,7 @@ protected:
|
||||
SEEK_WAIT_STEP_SIGNAL_TIME_DONE,
|
||||
SEEK_WAIT_STEP_TIME,
|
||||
SEEK_WAIT_STEP_TIME_DONE,
|
||||
SEEK_WAIT_DONE,
|
||||
SEEK_DONE,
|
||||
|
||||
HEAD_LOAD_DONE,
|
||||
|
Loading…
Reference in New Issue
Block a user