PCB K-3017 128K UNROM+same games.
128K Contra
other games ,is 512K or 1024K?
write 9F00+k*0x4,dump 8000-BFFF 16K,
data is 512K?
PCB K-3017 128K UNROM+same games.
Moderator: Moderators
- krzysiobal
- Posts: 1037
- Joined: Sun Jun 12, 2011 12:06 pm
- Location: Poland
- Contact:
Re: PCB K-3017 128K UNROM+same games.
Please brighter photo of bottom and photo from more angles of top.
- krzysiobal
- Posts: 1037
- Joined: Sun Jun 12, 2011 12:06 pm
- Location: Poland
- Contact:
- krzysiobal
- Posts: 1037
- Joined: Sun Jun 12, 2011 12:06 pm
- Location: Poland
- Contact:
Re: PCB K-3017 128K UNROM+same games.
Code: Select all
This cartridge switches between UNROM-128 and NROM mode every reset.
1. UNRO-128 MODE
PRG-ROM: 128 kB (using DIL28 memory)
CHR-RAM: 8 kB
Mirroring: vertical
Subject to bus conflicts: yes
When in UNROM-128 mode, it behaves exactly as mapper 2 (one UNROM game is stored
in DIL28 128 kB mask ROM).
2. NROM
PRG-ROM: 512 kB (using DIL32 memory)
CHR-RAM: 8 kB
Subject to bus conflicts for NROM: yes
When in NROM mode, there is one register at $8000-$ffff, written data does not matter
[1... .... wppp ppmv]
|||| ||||
|||| |||+- mode select: 0=16K, 1=32K
|||| ||+-- mirroring: 0=V, 1=H
|+++-++--- PRG bank
+--------- CHR-RAM write protection (1=enabled)
wv $8000 $c000
--------------
00 ppppp p0000
01 pppp0 p0000
10 ppppp ppppp
11 pppp0 pppp1
Interesting feature is that when w=0, c000 is always mapped to bank p000. This will allow the menu routine that is responsible for transferring CHR data from PRG-ROM to CHR-RAM to be placed here, instead of executing it from RAM, as almost every other multicart does.
---
#include "mapinc.h"
static uint8 reg;
static uint8 mode; //0=unrom,1nrom
static SFORMAT StateRegs[] =
{
{ 0 }
};
static void Sync(void) {
if (mode == 0) {
setmirror(MI_V);
setprg16(0x8000, 512/16 + reg);
setprg16(0xC000, 512/16 + 7);
}
else {
int p = (reg >> 2) & 0x1F;
setmirror(((reg >> 1) & 1) ? MI_H : MI_V);
switch ((((reg >> 7) & 1) << 1) | (((reg >> 0) & 1) << 0)) {
case 0:
setprg16(0x8000, p);
setprg16(0xc000, p & 0x10);
break;
case 1:
setprg16(0x8000, p & ~1);
setprg16(0xc000, p & 0x10);
break;
case 2:
setprg16(0x8000, p);
setprg16(0xc000, p);
break;
case 3:
setprg32(0x8000, p >> 1);
break;
}
}
}
static DECLFW(M280Write) {
if (mode == 0) {
reg = V & 7;
}
else {
reg = A & 0xFF;
}
Sync();
}
static void M280Power(void) {
reg = 0;
mode = 0;
setchr8(0);
SetWriteHandler(0x8000, 0xffff, M280Write);
SetReadHandler(0x8000, 0xFFFF, CartBR);
Sync();
}
static void M280Reset(void) {
mode ^= 1;
reg = 0;
Sync();
}
static void StateRestore(int version) {
Sync();
}
void Mapper280_Init(CartInfo *info) {
info->Power = M280Power;
info->Reset = M280Reset;
GameStateRestore = StateRestore;
AddExState(&StateRegs, ~0, 0, 0);
}
Re: PCB K-3017 128K UNROM+same games.
thank you!!
Re: PCB K-3017 128K UNROM+same games.
A variant of mapper #242