Initial commit
This commit is contained in:
commit
2149ab4d69
237 changed files with 493349 additions and 0 deletions
30
src/pse/system.cpp
Normal file
30
src/pse/system.cpp
Normal file
|
|
@ -0,0 +1,30 @@
|
|||
#include "system.h"
|
||||
|
||||
System::System() = default;
|
||||
|
||||
System::~System() = default;
|
||||
|
||||
bool System::Initialize()
|
||||
{
|
||||
if (!m_cpu.Initialize(&m_bus))
|
||||
return false;
|
||||
|
||||
if (!m_bus.Initialize(this, &m_dma, nullptr))
|
||||
return false;
|
||||
|
||||
if (!m_dma.Initialize(&m_bus, nullptr))
|
||||
return false;
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
void System::Reset()
|
||||
{
|
||||
m_cpu.Reset();
|
||||
m_bus.Reset();
|
||||
}
|
||||
|
||||
void System::RunFrame()
|
||||
{
|
||||
m_cpu.Execute();
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue