diff --git a/boot.rom b/boot.rom new file mode 100644 index 0000000..c32bcfc Binary files /dev/null and b/boot.rom differ diff --git a/build.sh b/build.sh index 0bcce11..587183c 100755 --- a/build.sh +++ b/build.sh @@ -89,25 +89,15 @@ then cp bin/uxnemu bin/uxnasm bin/uxncli $HOME/bin/ fi -bin/uxnasm projects/software/launcher.tal bin/launcher.rom -bin/uxnasm projects/software/asma.tal bin/asma.rom - if [ $norun = 1 ]; then exit; fi -# Test usage - -bin/uxnasm -bin/uxncli -bin/uxnemu - # Test version bin/uxnasm -v bin/uxncli -v bin/uxnemu -v -bin/uxnasm projects/examples/devices/mouse.tal bin/mouse.rom -bin/uxnemu -2x bin/mouse.rom +bin/uxnemu -2x # bin/uxnasm test.tal bin/test.rom # bin/uxncli bin/test.rom diff --git a/src/uxnemu.c b/src/uxnemu.c index 75843fc..744ecd7 100644 --- a/src/uxnemu.c +++ b/src/uxnemu.c @@ -499,7 +499,7 @@ main(int argc, char **argv) /* flags */ if(argc > 1 && argv[i][0] == '-') { if(!strcmp(argv[i], "-v")) - return system_error("Uxnemu - Varvara Emulator(GUI)", "18 Feb 2024."); + return system_error("Uxnemu - Varvara Emulator(GUI)", "22 Feb 2024."); else if(!strcmp(argv[i], "-2x")) set_zoom(2, 0); else if(!strcmp(argv[i], "-3x")) @@ -508,13 +508,11 @@ main(int argc, char **argv) set_fullscreen(1, 0); i++; } - if(i == argc) - return system_error("usage:", "uxnemu [-v | -f | -2x | -3x] file.rom [args...]"); /* start */ + rom = i == argc ? "boot.rom" : argv[i++]; ram = (Uint8 *)calloc(0x10000 * RAM_PAGES, sizeof(Uint8)); - rom = argv[i++]; if(!system_init(&u, ram, rom) || !system_init(&u_audio, ram, rom)) - return system_error("Init", "Failed to initialize uxn."); + return system_error("usage:", "uxnemu [-v | -f | -2x | -3x] file.rom [args...]"); if(!emu_init(&u_audio)) return system_error("Init", "Failed to initialize varvara."); /* loop */