mirror of
https://github.com/AppleWin/AppleWin.git
synced 2025-01-05 23:31:17 +00:00
DiskII: Allow stepper motor to change phase when motor is off, but during the ~1s when it's still spinning (#525)
This commit is contained in:
parent
4ef76f64bf
commit
da24cd6e60
@ -376,15 +376,23 @@ static void __stdcall DiskControlMotor(WORD, WORD address, BYTE, BYTE, ULONG uEx
|
||||
|
||||
static void __stdcall DiskControlStepper(WORD, WORD address, BYTE, BYTE, ULONG uExecutedCycles)
|
||||
{
|
||||
Disk_t * fptr = &g_aFloppyDisk[currdrive];
|
||||
|
||||
if (!floppymotoron) // GH#525
|
||||
{
|
||||
if (!fptr->spinning)
|
||||
{
|
||||
#if LOG_DISK_PHASES
|
||||
LOG_DISK("stepper accessed whilst motor is off\r\n");
|
||||
LOG_DISK("stepper accessed whilst motor is off and not spinning\r\n");
|
||||
#endif
|
||||
return;
|
||||
}
|
||||
|
||||
#if LOG_DISK_PHASES
|
||||
LOG_DISK("stepper accessed whilst motor is off, but still spinning\r\n");
|
||||
#endif
|
||||
return;
|
||||
}
|
||||
|
||||
Disk_t * fptr = &g_aFloppyDisk[currdrive];
|
||||
int phase = (address >> 1) & 3;
|
||||
int phase_bit = (1 << phase);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user