diff options
author | Andreas Baumann <mail@andreasbaumann.cc> | 2020-11-22 20:38:51 +0100 |
---|---|---|
committer | Andreas Baumann <mail@andreasbaumann.cc> | 2020-11-22 20:38:51 +0100 |
commit | 6c3401b8a2ce7a2dfe21a253f840f286088b1921 (patch) | |
tree | f49b1bba8b10c3b3681927764cd795e7af4ad9e5 /emu/emu.c | |
parent | 052899e196c6a2660651b9896ceed3313e7d0bac (diff) | |
download | 6502-6c3401b8a2ce7a2dfe21a253f840f286088b1921.tar.gz 6502-6c3401b8a2ce7a2dfe21a253f840f286088b1921.tar.bz2 |
more work on emulator
Diffstat (limited to 'emu/emu.c')
-rw-r--r-- | emu/emu.c | 13 |
1 files changed, 10 insertions, 3 deletions
@@ -6,16 +6,23 @@ int main( int argc, char *argv[] ) { + emul_t emul; 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.debug = true; cpu_6502_reset( &cpu ); - cpu_6502_run( &cpu ); + emul_init( &emul, &cpu, &memory ); + emul.gui = true; + emul_start( &emul ); + + emul_run( &emul ); + + emul_free( &emul ); exit( EXIT_SUCCESS ); } |