42 lines
874 B
C
42 lines
874 B
C
/*
|
|
* =====================================================================================
|
|
*
|
|
* Filename: main.c
|
|
*
|
|
* Description: Emulator main loop
|
|
*
|
|
* Version: 1.0
|
|
* Created: 2023-09-21 09:50:34 PM
|
|
* Revision: none
|
|
* Compiler: gcc
|
|
*
|
|
* Author: William Nolin,
|
|
* Organization:
|
|
*
|
|
* =====================================================================================
|
|
*/
|
|
#include <stdlib.h>
|
|
#include "log.h"
|
|
#include "debugger/debugger.h"
|
|
|
|
#include "include/rom.h"
|
|
#include "include/system.h"
|
|
|
|
int main() {
|
|
log_set_level(LOG_INFO);
|
|
system_init();
|
|
|
|
char *rom_path = "../test_roms/smb.nes";
|
|
|
|
if (!rom_load(rom_path)) {
|
|
system_uninit();
|
|
return EXIT_FAILURE;
|
|
}
|
|
|
|
system_start();
|
|
// start_debugger();
|
|
system_loop();
|
|
|
|
system_uninit();
|
|
return EXIT_SUCCESS;
|
|
} |