mirror of https://github.com/mgba-emu/mgba.git
GB: Reset with initial state of DIV register
This commit is contained in:
parent
3a03d180d2
commit
d5c5173889
1
CHANGES
1
CHANGES
|
@ -139,6 +139,7 @@ Misc:
|
||||||
- GBA Memory: Remove unused prefetch cruft
|
- GBA Memory: Remove unused prefetch cruft
|
||||||
- GB: Trust ROM header for number of SRAM banks (fixes mgba.io/i/726)
|
- GB: Trust ROM header for number of SRAM banks (fixes mgba.io/i/726)
|
||||||
- Core: Config values can now be hexadecimal
|
- Core: Config values can now be hexadecimal
|
||||||
|
- GB: Reset with initial state of DIV register
|
||||||
|
|
||||||
0.5.2: (2016-12-31)
|
0.5.2: (2016-12-31)
|
||||||
Bugfixes:
|
Bugfixes:
|
||||||
|
|
|
@ -433,6 +433,7 @@ void GBReset(struct LR35902Core* cpu) {
|
||||||
cpu->e = 0xD8;
|
cpu->e = 0xD8;
|
||||||
cpu->h = 1;
|
cpu->h = 1;
|
||||||
cpu->l = 0x4D;
|
cpu->l = 0x4D;
|
||||||
|
gb->timer.internalDiv = 0x2AF3;
|
||||||
break;
|
break;
|
||||||
case GB_MODEL_AGB:
|
case GB_MODEL_AGB:
|
||||||
cpu->b = 1;
|
cpu->b = 1;
|
||||||
|
@ -444,6 +445,7 @@ void GBReset(struct LR35902Core* cpu) {
|
||||||
cpu->e = 0x08;
|
cpu->e = 0x08;
|
||||||
cpu->h = 0;
|
cpu->h = 0;
|
||||||
cpu->l = 0x7C;
|
cpu->l = 0x7C;
|
||||||
|
gb->timer.internalDiv = 0x7A8;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue