diff --git a/WinBoyEmulator/GameBoy/CPU/LR35902.cs b/WinBoyEmulator/GameBoy/CPU/LR35902.cs index b7a17f1..75d6387 100644 --- a/WinBoyEmulator/GameBoy/CPU/LR35902.cs +++ b/WinBoyEmulator/GameBoy/CPU/LR35902.cs @@ -233,6 +233,20 @@ public static LR35902 Instance } } + public void Start() + { + var cpuIsRunning = true; + /*while(cpuIsRunning) + { + // Issue #32 + // + // Fetch instruction + // Dispatch + // Mask PC to 16 bits + // Add time to CPU clock + }*/ + } + public void Reset() { // Since we have combined registers, we can use them. diff --git a/WinBoyEmulator/GameBoy/Emulator.cs b/WinBoyEmulator/GameBoy/Emulator.cs index fd6bdca..9d729f9 100644 --- a/WinBoyEmulator/GameBoy/Emulator.cs +++ b/WinBoyEmulator/GameBoy/Emulator.cs @@ -79,6 +79,7 @@ public void StartEmulation(string gamePath) // Load game. _readGameFile(gamePath); MMU.Instance.Load(_game); + LR35902.Instance.Start(); } } }