openMSX
RomNettouYakyuu.hh
Go to the documentation of this file.
1 #ifndef ROMNETTOUYAKYUU_HH
2 #define ROMNETTOUYAKYUU_HH
3 
4 #include "RomBlocks.hh"
5 
6 namespace openmsx {
7 
8 class SamplePlayer;
9 
11 {
12 public:
13  RomNettouYakyuu(const DeviceConfig& config, std::unique_ptr<Rom> rom);
14  virtual ~RomNettouYakyuu();
15 
16  virtual void reset(EmuTime::param time);
17  virtual void writeMem(word address, byte value, EmuTime::param time);
18  virtual byte* getWriteCacheLine(word address) const;
19 
20  template<typename Archive>
21  void serialize(Archive& ar, unsigned version);
22 
23 private:
24  const std::unique_ptr<SamplePlayer> samplePlayer;
25 
26  // remember per region if writes are for the sample player or not
27  // there are 4 x 8kB regions in [0x4000-0xBFFF]
28  bool redirectToSamplePlayer[4];
29 };
30 
31 } // namespace openmsx
32 
33 #endif
unsigned char byte
8 bit unsigned integer
Definition: openmsx.hh:33
void serialize(Archive &ar, unsigned version)
virtual void writeMem(word address, byte value, EmuTime::param time)
Write a given byte to a given location at a certain time to this device.
unsigned short word
16 bit unsigned integer
Definition: openmsx.hh:38
virtual byte * getWriteCacheLine(word address) const
Test that the memory in the interval [start, start + CacheLine::SIZE) is cacheable for writing...
const std::unique_ptr< Rom > rom
Definition: MSXRom.hh:24
virtual void reset(EmuTime::param time)
This method is called on reset.
RomNettouYakyuu(const DeviceConfig &config, std::unique_ptr< Rom > rom)