20 void powerUp(EmuTime::param time)
override;
21 void reset(EmuTime::param time)
override;
23 [[nodiscard]]
byte readMem(
word address, EmuTime::param time)
override;
24 void writeMem(
word address,
byte value, EmuTime::param time)
override;
27 template<
typename Archive>
28 void serialize(Archive& ar,
unsigned version);
31 [[nodiscard]]
byte getBank()
const;
32 void writeControl(
byte value);
34 [[nodiscard]]
byte readDataLow(EmuTime::param time);
35 [[nodiscard]]
byte readDataHigh(EmuTime::param time)
const;
36 [[nodiscard]]
word readData(EmuTime::param time);
37 [[nodiscard]]
byte readReg(
nibble reg, EmuTime::param time);
38 void writeDataLow(
byte value);
39 void writeDataHigh(
byte value, EmuTime::param time);
40 void writeData(
word value, EmuTime::param time);
41 void writeReg(
nibble reg,
byte value, EmuTime::param time);
46 [[nodiscard]]
byte read(
unsigned address)
override;
50 std::array<std::unique_ptr<IDEDevice>, 2> device;
51 std::span<const byte, 0x4000> internalBank;
56 bool ideRegsEnabled =
false;
An MSXDevice is an emulated hardware component connected to the bus of the emulated MSX.
void reset(EmuTime::param time) override
This method is called on reset.
SunriseIDE(const DeviceConfig &config)
void writeMem(word address, byte value, EmuTime::param time) override
Write a given byte to a given location at a certain time to this device.
void serialize(Archive &ar, unsigned version)
const byte * getReadCacheLine(word start) const override
Test that the memory in the interval [start, start + CacheLine::SIZE) is cacheable for reading.
void powerUp(EmuTime::param time) override
This method is called when MSX is powered up.
byte readMem(word address, EmuTime::param time) override
Read a byte from a location at a certain time from this device.
This file implemented 3 utility functions:
uint8_t nibble
4 bit integer
uint16_t word
16 bit unsigned integer