Esempio n. 1
0
        public void Reset()
        {
            var wasTurnedOn = _turnedOn;

            _turnedOn = false;
            Wait();

            Cpu.Reset();
            Mmu.Reset();
            Gpu.Reset();

            // Draw blank frame buffer
            OnDrawScreen?.Invoke(this,
                                 new DrawScreenEventArgs(Gpu.FrameBuffer));

            _paused = false;

            if (wasTurnedOn)
            {
                PowerOn();
            }
        }
Esempio n. 2
0
 public static Console Default()
 {
     var mmu = new Mmu();
     var cpu = new Cpu(mmu);
     var gpu = new Gpu(mmu);
     var timer = new Timer(mmu);
     var controller = new Controller(mmu);
     return new Console(cpu, mmu, gpu, timer, controller);
 }