summaryrefslogtreecommitdiff
path: root/emu/emu.c
blob: fbd9bb7a0d8334dd20a977d144ae65697e5e96ef (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
#include "emul.h"
#include "6502.h"
#include "memory.h"

#include <stdlib.h>

int main( int argc, char *argv[] )
{
	cpu_6502_t cpu;
	memory_t memory;
	
	memory_init( &memory );
	memory_load( &memory, ROM_START, ROM_SIZE, "./rom.bin" );
	
	cpu_6502_init( &cpu, &memory );
	cpu.debug = true;
	cpu_6502_reset( &cpu );
	cpu_6502_run( &cpu );
	
	exit( EXIT_SUCCESS );
}