14 class SectorAccessibleDisk;
20 using Drives = std::vector<std::unique_ptr<DiskContainer>>;
32 [[nodiscard]]
byte peek()
const;
37 void write(
byte data,
unsigned time);
45 template<
typename Archive>
46 void serialize(Archive& ar,
unsigned version);
63 void executeCommand();
65 void send(
byte value);
66 void send16(
word value);
76 [[nodiscard]]
unsigned getSectorAmount()
const;
77 [[nodiscard]]
unsigned getStartSector()
const;
78 [[nodiscard]]
unsigned getStartAddress()
const;
79 [[nodiscard]]
unsigned getCurrentAddress()
const;
84 void transferSectors(
unsigned transferAddress,
unsigned amount);
85 void transferSectorsBackwards(
unsigned transferAddress,
unsigned amount);
91 [[nodiscard]]
unsigned getFCB()
const;
92 [[nodiscard]] std::string extractName(
int begin,
int end)
const;
93 unsigned readHelper1(
unsigned dev,
char* buffer);
94 void readHelper2(
unsigned len,
const char* buffer);
95 [[nodiscard]]
int getDeviceNum()
const;
96 int getFreeDeviceNum();
102 void callImage(
const std::string&
filename);
105 static constexpr
unsigned MAX_DEVICES = 16;
112 std::unique_ptr<std::fstream>
fs;
114 } devices[MAX_DEVICES];
117 std::vector<SectorBuffer> buffer;
121 unsigned transferred;
123 unsigned transferSize;
125 byte extraData[240 + 2];
128 bool allowOtherDiskroms;
129 bool enablePhantomDrives;
std::unique_ptr< std::fstream > fs
NowindHost(const Drives &drives)
void serialize(Archive &ar, unsigned version)
void setEnablePhantomDrives(bool enable)
void write(byte data, unsigned time)
std::vector< std::unique_ptr< DiskContainer > > Drives
bool getAllowOtherDiskroms() const
void setAllowOtherDiskroms(bool allow)
bool isDataAvailable() const
bool getEnablePhantomDrives() const
This file implemented 3 utility functions:
constexpr const char *const filename
uint16_t word
16 bit unsigned integer
constexpr auto begin(const zstring_view &x)
constexpr auto end(const zstring_view &x)