1
0
mirror of https://github.com/TomHarte/CLK.git synced 2025-08-05 08:26:28 +00:00

Makes disk head position explicitly something with sub-integral precision.

Also as a drive-by fix, corrects accidental assumption of 10 sectors for all MFMSectorDump descendants.
This commit is contained in:
Thomas Harte
2018-05-06 23:17:36 -04:00
parent 1139caa83f
commit f65c65569a
40 changed files with 135 additions and 97 deletions

View File

@@ -115,7 +115,7 @@ void i8272::run_for(Cycles cycles) {
int direction = (drives_[c].target_head_position < drives_[c].head_position) ? -1 : 1;
printf("Target %d versus believed %d\n", drives_[c].target_head_position, drives_[c].head_position);
select_drive(c);
get_drive().step(direction);
get_drive().step(Storage::Disk::HeadPosition(direction));
if(drives_[c].target_head_position >= 0) drives_[c].head_position += direction;
// Check for completion.