|
openMSX
|
This class connects to a FDC as a normal DiskDrive and deligates all requests to one of four other DiskDrives. More...
#include <DriveMultiplexer.hh>


Public Types | |
| enum | DriveNum { DRIVE_A = 0, DRIVE_B = 1, DRIVE_C = 2, DRIVE_D = 3, NO_DRIVE = 4 } |
Public Member Functions | |
| DriveMultiplexer (DiskDrive *drive[4]) | |
| virtual | ~DriveMultiplexer () |
| void | selectDrive (DriveNum num, EmuTime::param time) |
| virtual bool | isDiskInserted () const |
| Is drive ready? | |
| virtual bool | isWriteProtected () const |
| Is disk write protected? | |
| virtual bool | isDoubleSided () const |
| Is disk double sided? | |
| virtual bool | isTrack00 () const |
| Head above track 0. | |
| virtual void | setSide (bool side) |
| Side select. | |
| virtual void | step (bool direction, EmuTime::param time) |
| Step head. | |
| virtual void | setMotor (bool status, EmuTime::param time) |
| Set motor on/off. | |
| virtual bool | indexPulse (EmuTime::param time) |
| Gets the state of the index pulse. | |
| virtual EmuTime | getTimeTillIndexPulse (EmuTime::param time, int count) |
| Return the time till the start of the next index pulse When there is no disk in the drive or when the disk is not spinning, this function returns the current time. | |
| virtual void | setHeadLoaded (bool status, EmuTime::param time) |
| Set head loaded status. | |
| virtual bool | headLoaded (EmuTime::param time) |
| Is head loaded? | |
| virtual void | writeTrack (const RawTrack &track) |
| virtual void | readTrack (RawTrack &track) |
| virtual EmuTime | getNextSector (EmuTime::param time, RawTrack &track, RawTrack::Sector §or) |
| virtual bool | diskChanged () |
| Is disk changed? | |
| virtual bool | peekDiskChanged () const |
| virtual bool | isDummyDrive () const |
| Is there a dummy (unconncted) drive? | |
| template<typename Archive > | |
| void | serialize (Archive &ar, unsigned version) |
Public Member Functions inherited from openmsx::DiskDrive | |
| virtual | ~DiskDrive () |
Additional Inherited Members | |
Static Public Attributes inherited from openmsx::DiskDrive | |
| static const unsigned | ROTATIONS_PER_SECOND = 5 |
This class connects to a FDC as a normal DiskDrive and deligates all requests to one of four other DiskDrives.
Definition at line 12 of file DriveMultiplexer.hh.
Definition at line 15 of file DriveMultiplexer.hh.
|
explicit |
|
virtual |
Definition at line 20 of file DriveMultiplexer.cc.
|
virtual |
Is disk changed?
Implements openmsx::DiskDrive.
Definition at line 107 of file DriveMultiplexer.cc.
References openmsx::DiskDrive::diskChanged().
|
virtual |
Implements openmsx::DiskDrive.
Definition at line 101 of file DriveMultiplexer.cc.
References openmsx::DiskDrive::getNextSector().
|
virtual |
Return the time till the start of the next index pulse When there is no disk in the drive or when the disk is not spinning, this function returns the current time.
| time | The current time |
| count | Number of required index pulses. |
Implements openmsx::DiskDrive.
Definition at line 76 of file DriveMultiplexer.cc.
References openmsx::DiskDrive::getTimeTillIndexPulse().
|
virtual |
Is head loaded?
Implements openmsx::DiskDrive.
Definition at line 86 of file DriveMultiplexer.cc.
References openmsx::DiskDrive::headLoaded().
|
virtual |
Gets the state of the index pulse.
| time | The moment in emulated time to get the pulse state for. |
Implements openmsx::DiskDrive.
Definition at line 71 of file DriveMultiplexer.cc.
References openmsx::DiskDrive::indexPulse().
|
virtual |
Is drive ready?
Implements openmsx::DiskDrive.
Definition at line 34 of file DriveMultiplexer.cc.
References openmsx::DiskDrive::isDiskInserted().
|
virtual |
Is disk double sided?
Implements openmsx::DiskDrive.
Definition at line 44 of file DriveMultiplexer.cc.
References openmsx::DiskDrive::isDoubleSided().
|
virtual |
Is there a dummy (unconncted) drive?
Implements openmsx::DiskDrive.
Definition at line 117 of file DriveMultiplexer.cc.
References openmsx::DiskDrive::isDummyDrive().
|
virtual |
Head above track 0.
Implements openmsx::DiskDrive.
Definition at line 60 of file DriveMultiplexer.cc.
References openmsx::DiskDrive::isTrack00().
|
virtual |
Is disk write protected?
Implements openmsx::DiskDrive.
Definition at line 39 of file DriveMultiplexer.cc.
References openmsx::DiskDrive::isWriteProtected().
|
virtual |
Implements openmsx::DiskDrive.
Definition at line 112 of file DriveMultiplexer.cc.
References openmsx::DiskDrive::peekDiskChanged().
|
virtual |
Implements openmsx::DiskDrive.
Definition at line 96 of file DriveMultiplexer.cc.
References openmsx::DiskDrive::readTrack().
| void openmsx::DriveMultiplexer::selectDrive | ( | DriveNum | num, |
| EmuTime::param | time | ||
| ) |
Definition at line 24 of file DriveMultiplexer.cc.
References openmsx::DiskDrive::setMotor(), and openmsx::DiskDrive::setSide().
| void openmsx::DriveMultiplexer::serialize | ( | Archive & | ar, |
| unsigned | version | ||
| ) |
Definition at line 133 of file DriveMultiplexer.cc.
|
virtual |
Set head loaded status.
| status | false = not loaded, true = loaded. |
| time | The moment in emulated time this action takes place. |
Implements openmsx::DiskDrive.
Definition at line 81 of file DriveMultiplexer.cc.
References openmsx::DiskDrive::setHeadLoaded().
|
virtual |
Set motor on/off.
| status | false = off, true = on. |
| time | The moment in emulated time this action takes place. |
Implements openmsx::DiskDrive.
Definition at line 65 of file DriveMultiplexer.cc.
References openmsx::DiskDrive::setMotor().
|
virtual |
Side select.
| side | false = side 0, true = side 1. |
Implements openmsx::DiskDrive.
Definition at line 49 of file DriveMultiplexer.cc.
References openmsx::DiskDrive::setSide().
|
virtual |
Step head.
| direction | false = out, true = in. |
| time | The moment in emulated time this action takes place. |
Implements openmsx::DiskDrive.
Definition at line 55 of file DriveMultiplexer.cc.
References openmsx::DiskDrive::step().
|
virtual |
Implements openmsx::DiskDrive.
Definition at line 91 of file DriveMultiplexer.cc.
References openmsx::DiskDrive::writeTrack().
1.8.1.2