Example #1
0
        public void Reset(bool inBios = false, Cartridge cartridge = null)
        {
            CyclesCount = 0;
            Cpu.Reset(inBios, cartridge);
            Mmu.Reset();
            Ppu.Reset();
            Apu.Reset();
            Input.Reset();
            Timer.Reset();
            Dma.Reset();
            LinkCable.Reset();
            IsAlive = true;

            frameQueue = new FrameQueue();
        }
Example #2
0
        public Gameboy(ConstructAudioEmitter constructor)
        {
            ConstructEmitter = constructor;
            Mmu   = new MMU(this);
            Ppu   = new PPU(this);
            Apu   = new APU(this);
            Input = new Input(this);
            Timer = new Timer(this);

            Cpu       = new CPU(this);
            Dma       = new DMA(this);
            LinkCable = new LinkCable(this);

            Reset();
        }