Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/ClusterM/fceux.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authormjbudd77 <44712797+mjbudd77@users.noreply.github.com>2022-03-07 05:49:01 +0300
committerGitHub <noreply@github.com>2022-03-07 05:49:01 +0300
commit3acbdc1c5a927f3bbe0b2084f48ef75290f29340 (patch)
tree070bfab1af01316b52a0a018bb9097b1c49b49a0 /src
parent3e7dc3474a5511d9ec37b63c30e19b9feadc57c8 (diff)
parent7f4eb7e14fc58b3470bec3f571d17cd950dfcc6d (diff)
Merge pull request #473 from negativeExponent/m225_extra_ram
Mapper 225: Implement extra RAM
Diffstat (limited to 'src')
-rw-r--r--src/boards/225.cpp12
1 files changed, 11 insertions, 1 deletions
diff --git a/src/boards/225.cpp b/src/boards/225.cpp
index fd008ea2..e8237ed6 100644
--- a/src/boards/225.cpp
+++ b/src/boards/225.cpp
@@ -52,15 +52,23 @@ static DECLFW(M225Write) {
}
static DECLFW(M225LoWrite) {
+ if (A & 0x800) {
+ prot[A & 0x03] = V;
+ }
}
static DECLFR(M225LoRead) {
- return 0;
+ if (A & 0x800) {
+ return prot[A & 3] & 0x0F;
+ }
+ return X.DB;
}
static void M225Power(void) {
prg = 0;
+ chr = 0;
mode = 0;
+ mirr = 0;
Sync();
SetReadHandler(0x5000, 0x5FFF, M225LoRead);
SetWriteHandler(0x5000, 0x5FFF, M225LoWrite);
@@ -70,7 +78,9 @@ static void M225Power(void) {
static void M225Reset(void) {
prg = 0;
+ chr = 0;
mode = 0;
+ mirr = 0;
Sync();
}