openMSX
RomNettouYakyuu.hh
Go to the documentation of this file.
1 #ifndef ROMNETTOUYAKYUU_HH
2 #define ROMNETTOUYAKYUU_HH
3 
4 #include "RomBlocks.hh"
5 #include "SamplePlayer.hh"
6 
7 namespace openmsx {
8 
9 class RomNettouYakyuu final : public Rom8kBBlocks
10 {
11 public:
12  RomNettouYakyuu(const DeviceConfig& config, Rom&& rom);
13 
14  void reset(EmuTime::param time) override;
15  void writeMem(word address, byte value, EmuTime::param time) override;
16  byte* getWriteCacheLine(word address) const override;
17 
18  template<typename Archive>
19  void serialize(Archive& ar, unsigned version);
20 
21 private:
22  SamplePlayer samplePlayer;
23 
24  // remember per region if writes are for the sample player or not
25  // there are 4 x 8kB regions in [0x4000-0xBFFF]
26  bool redirectToSamplePlayer[4];
27 };
28 
29 } // namespace openmsx
30 
31 #endif
openmsx::RomNettouYakyuu::RomNettouYakyuu
RomNettouYakyuu(const DeviceConfig &config, Rom &&rom)
Definition: RomNettouYakyuu.cc:47
openmsx::DeviceConfig
Definition: DeviceConfig.hh:20
openmsx::RomNettouYakyuu::reset
void reset(EmuTime::param time) override
This method is called on reset.
Definition: RomNettouYakyuu.cc:58
openmsx::RomBlocks
Definition: RomBlocks.hh:14
openmsx::MSXRom::rom
Rom rom
Definition: MSXRom.hh:20
openmsx::Rom
Definition: Rom.hh:21
openmsx::RomNettouYakyuu::writeMem
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.
Definition: RomNettouYakyuu.cc:73
openmsx::word
uint16_t word
16 bit unsigned integer
Definition: openmsx.hh:29
openmsx::RomNettouYakyuu::serialize
void serialize(Archive &ar, unsigned version)
Definition: RomNettouYakyuu.cc:117
openmsx::SamplePlayer
Definition: SamplePlayer.hh:11
SamplePlayer.hh
openmsx::RomNettouYakyuu
Definition: RomNettouYakyuu.hh:10
openmsx::RomNettouYakyuu::getWriteCacheLine
byte * getWriteCacheLine(word address) const override
Test that the memory in the interval [start, start + CacheLine::SIZE) is cacheable for writing.
Definition: RomNettouYakyuu.cc:111
openmsx
This file implemented 3 utility functions:
Definition: Autofire.cc:5
RomBlocks.hh