Compare commits
2
Commits
f6478da541
...
379ff3babf
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
379ff3babf | ||
|
|
cee8ffabb3 |
+6
-2
@@ -56,7 +56,11 @@ $ ./vendor/ruc/script/pre-commit.sh install
|
|||||||
|
|
||||||
*** Opcodes
|
*** Opcodes
|
||||||
|
|
||||||
- https://www.pastraiser.com/cpu/gameboy/gameboy_opcodes.html
|
- https://gbdev.io/gb-opcodes/optables/
|
||||||
- https://github.com/lmmendes/game-boy-opcodes
|
- https://gb.insertcoin.dev/
|
||||||
- https://rgbds.gbdev.io/docs/v0.5.2/gbz80.7/
|
- https://rgbds.gbdev.io/docs/v0.5.2/gbz80.7/
|
||||||
- https://gbdev.io/pandocs/CPU_Instruction_Set.html
|
- https://gbdev.io/pandocs/CPU_Instruction_Set.html
|
||||||
|
|
||||||
|
*** Bootroms
|
||||||
|
|
||||||
|
https://github.com/ISSOtm/gb-bootroms
|
||||||
|
|||||||
+7
-4
@@ -28,10 +28,13 @@ int main(int argc, char* argv[])
|
|||||||
Emu::the().addProcessingUnit("cpu", &cpu);
|
Emu::the().addProcessingUnit("cpu", &cpu);
|
||||||
Emu::the().addProcessingUnit("ppu", &ppu);
|
Emu::the().addProcessingUnit("ppu", &ppu);
|
||||||
|
|
||||||
Emu::the().addMemorySpace("RAM", 1024);
|
// https://gbdev.io/pandocs/Memory_Map.html
|
||||||
Emu::the().addMemorySpace("VRAM", 1024);
|
Emu::the().addMemorySpace("CARDROM", (1 + 0x3fff - 0x0000)); // 16KiB
|
||||||
Emu::the().addMemorySpace("ROM", 1024);
|
Emu::the().addMemorySpace("VRAM", (1 + 0x9fff - 0x8000) * 2); // 8KiB * 2 banks
|
||||||
Emu::the().addMemorySpace("CARDROM", 1024);
|
Emu::the().addMemorySpace("CARDRAM", (1 + 0xbfff - 0xa000)); // 8KiB
|
||||||
|
Emu::the().addMemorySpace("WRAM", (1 + 0xcfff - 0xc000) + (1 + 0xdfff - 0xd000) * 7); // 4 KiB + 4 KiB * 7 banks, Work RAM
|
||||||
|
Emu::the().addMemorySpace("ECHORAM", (1 + 0xfdff - 0xe000)); // 7679B, Mirror of 0xc000~0xddff
|
||||||
|
Emu::the().addMemorySpace("HRAM", (1 + 0xfffe - 0xff80)); // 126B, High RAM (CPU cache)
|
||||||
|
|
||||||
// Get shared register
|
// Get shared register
|
||||||
print("{}\n", *Emu::the().processingUnit("cpu")->sharedRegister("a"));
|
print("{}\n", *Emu::the().processingUnit("cpu")->sharedRegister("a"));
|
||||||
|
|||||||
Reference in New Issue
Block a user