@echo on
cd %2
\Utils\Asw\bin\asw %1 -CPU 6809  -L -olist \BldVTX\Listing.txt  -D BuildVTX -o \BldVTX\prog.bld
if not "%errorlevel%"=="0" goto Abandon
\Utils\Asw\bin\p2bin \BldVTX\prog.bld \BldVTX\prog.bin
rem \Utils\Vasm\vasm6502_oldstyle_win32.exe %1 -c02 -chklabels -nocase -Dvasm=1  -L \BldAP2\Listing.txt -DBuildVTX=1 -Fbin -o "\BldVTX\Prog.bin"
if not "%errorlevel%"=="0" goto Abandon

cd \Emu\VecGL

rem superfast
vecxgl -x 1000 -b myrom.dat \BldVTX\Prog.bin
rem fastish
rem vecxgl -x 500 -b myrom2.dat \BldVTX\Prog.bin



:Abandon
if "%3"=="nopause" exit
pause
