1
0
mirror of https://github.com/TomHarte/CLK.git synced 2026-04-26 19:17:52 +00:00

Started on the SSD/DSD support. Realised I had ommitted multiple head support from my disk class. Fixed that.

This commit is contained in:
Thomas Harte
2016-09-18 19:21:02 -04:00
parent 5409c8ec54
commit 91cd7e143b
11 changed files with 123 additions and 10 deletions
+2 -1
View File
@@ -54,13 +54,14 @@ unsigned int G64::get_head_position_count()
return _number_of_tracks > 84 ? _number_of_tracks : 84;
}
std::shared_ptr<Track> G64::get_track_at_position(unsigned int position)
std::shared_ptr<Track> G64::get_track_at_position(unsigned int head, unsigned int position)
{
std::shared_ptr<Track> resulting_track;
// if there's definitely no track here, return the empty track
// (TODO: should be supplying one with an index hole?)
if(position >= _number_of_tracks) return resulting_track;
if(head >= 1) return resulting_track;
// seek to this track's entry in the track table
fseek(_file, (long)((position * 4) + 0xc), SEEK_SET);