openMSX
GoudaSCSI.hh
Go to the documentation of this file.
1 #ifndef GOUDASCSI_HH
2 #define GOUDASCSI_HH
3 
4 #include "MSXDevice.hh"
5 #include "Rom.hh"
6 #include "WD33C93.hh"
7 
8 namespace openmsx {
9 
10 class GoudaSCSI final : public MSXDevice
11 {
12 public:
13  explicit GoudaSCSI(const DeviceConfig& config);
14 
15  void reset(EmuTime::param time) override;
16 
17  byte readMem(word address, EmuTime::param time) override;
18  const byte* getReadCacheLine(word start) const override;
19  byte readIO(word port, EmuTime::param time) override;
20  void writeIO(word port, byte value, EmuTime::param time) override;
21  byte peekIO(word port, EmuTime::param time) const override;
22 
23  template<typename Archive>
24  void serialize(Archive& ar, unsigned version);
25 
26 private:
27  Rom rom;
28  WD33C93 wd33c93;
29 };
30 
31 } // namespace openmsx
32 
33 #endif
openmsx::GoudaSCSI::serialize
void serialize(Archive &ar, unsigned version)
Definition: GoudaSCSI.cc:77
openmsx::MSXDevice
An MSXDevice is an emulated hardware component connected to the bus of the emulated MSX.
Definition: MSXDevice.hh:31
WD33C93.hh
openmsx::GoudaSCSI::reset
void reset(EmuTime::param time) override
This method is called on reset.
Definition: GoudaSCSI.cc:15
Rom.hh
openmsx::GoudaSCSI::readIO
byte readIO(word port, EmuTime::param time) override
Read a byte from an IO port at a certain time from this device.
Definition: GoudaSCSI.cc:20
openmsx::GoudaSCSI::peekIO
byte peekIO(word port, EmuTime::param time) const override
Read a byte from a given IO port.
Definition: GoudaSCSI.cc:34
openmsx::DeviceConfig
Definition: DeviceConfig.hh:19
openmsx::GoudaSCSI::GoudaSCSI
GoudaSCSI(const DeviceConfig &config)
Definition: GoudaSCSI.cc:7
openmsx::GoudaSCSI::readMem
byte readMem(word address, EmuTime::param time) override
Read a byte from a location at a certain time from this device.
Definition: GoudaSCSI.cc:65
MSXDevice.hh
openmsx::Rom
Definition: Rom.hh:20
openmsx::GoudaSCSI::writeIO
void writeIO(word port, byte value, EmuTime::param time) override
Write a byte to a given IO port at a certain time to this device.
Definition: GoudaSCSI.cc:48
openmsx::WD33C93
Definition: WD33C93.hh:23
openmsx::word
uint16_t word
16 bit unsigned integer
Definition: openmsx.hh:29
openmsx::GoudaSCSI
Definition: GoudaSCSI.hh:10
openmsx
Thanks to enen for testing this on a real cartridge:
Definition: Autofire.cc:5
openmsx::GoudaSCSI::getReadCacheLine
const byte * getReadCacheLine(word start) const override
Test that the memory in the interval [start, start + CacheLine::SIZE) is cacheable for reading.
Definition: GoudaSCSI.cc:70