mirror of
https://github.com/SourMesen/Mesen.git
synced 2025-04-02 10:52:48 -04:00
Mapper 180 support
This commit is contained in:
parent
0ce7e91e74
commit
c71af2b9d9
4 changed files with 29 additions and 0 deletions
|
@ -285,6 +285,7 @@
|
|||
<ClInclude Include="TriangleChannel.h" />
|
||||
<ClInclude Include="UnlPci556.h" />
|
||||
<ClInclude Include="UNROM.h" />
|
||||
<ClInclude Include="UnRom_180.h" />
|
||||
<ClInclude Include="VideoDecoder.h" />
|
||||
<ClInclude Include="BaseVideoFilter.h" />
|
||||
<ClInclude Include="VirtualController.h" />
|
||||
|
|
|
@ -344,6 +344,9 @@
|
|||
<ClInclude Include="SoundMixer.h">
|
||||
<Filter>Nes\APU</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="UnRom_180.h">
|
||||
<Filter>Nes\Mappers</Filter>
|
||||
</ClInclude>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClCompile Include="stdafx.cpp">
|
||||
|
|
|
@ -38,6 +38,7 @@
|
|||
#include "TaitoX1005.h"
|
||||
#include "UnlPci556.h"
|
||||
#include "UNROM.h"
|
||||
#include "UnRom_180.h"
|
||||
#include "VRC1.h"
|
||||
#include "VRC2_4.h"
|
||||
#include "BF909x.h"
|
||||
|
@ -95,6 +96,7 @@ BaseMapper* MapperFactory::GetMapperFromID(ROMLoader &romLoader)
|
|||
case 152: return new Bandai74161_7432(true);
|
||||
case 154: return new Namco108_154();
|
||||
case 163: return new Nanjing();
|
||||
case 180: return new UnRom_180();
|
||||
case 184: return new Sunsoft184();
|
||||
case 185: return new CNROM(true);
|
||||
case 189: return new MMC3_189();
|
||||
|
|
23
Core/UnRom_180.h
Normal file
23
Core/UnRom_180.h
Normal file
|
@ -0,0 +1,23 @@
|
|||
#pragma once
|
||||
#include "stdafx.h"
|
||||
#include "BaseMapper.h"
|
||||
|
||||
class UnRom_180 : public BaseMapper
|
||||
{
|
||||
protected:
|
||||
virtual uint16_t GetPRGPageSize() { return 0x4000; }
|
||||
virtual uint16_t GetCHRPageSize() { return 0x2000; }
|
||||
|
||||
void InitMapper()
|
||||
{
|
||||
SelectPRGPage(0, 0);
|
||||
SelectPRGPage(1, -1);
|
||||
|
||||
SelectCHRPage(0, 0);
|
||||
}
|
||||
|
||||
void WriteRegister(uint16_t addr, uint8_t value)
|
||||
{
|
||||
SelectPRGPage(1, value & 0x07);
|
||||
}
|
||||
};
|
Loading…
Add table
Reference in a new issue