@cd new
@mkdir 2 3 4


@cd 1



@cd ..\2
@rem ** Velocizziamo il tutto **
@rem @copy /Y ..\..\src\2\flash.nb0.os.nb .\
@rem ..\..\Tools\osnbtool -c ..\..\src\2\flash.nb0.os.nb 1 ..\1\xip.bin
@rem ..\..\Tools\osnbtool -c flash.nb0.os.nb.NEW 2 ..\1\imgfs.bin

..\..\Tools\osnbtool -c ..\..\src\2\flash.nb0.os.nb 2 ..\0\empty_imgfs.bin
@move ..\..\src\2\flash.nb0.os.nb.NEW flash.nb0.os.nb
..\..\Tools\osnbtool -c flash.nb0.os.nb 1 ..\1\xip.bin
..\..\Tools\osnbtool -c flash.nb0.os.nb.NEW 2 ..\1\imgfs.bin


@cd ..\3
@copy /Y ..\..\src\2\flash.nb0.PRE .\
..\..\Tools\osnbtool -extra ..\2\flash.nb0.os.nb.NEW.NEW
move ..\2\flash.nb0.OS.NB.NEW.NEW.EXA .\
copy /B /Y flash.nb0.PRE + flash.nb0.OS.NB.NEW.NEW.EXA ..\4\FLASH.nb0

cd ..\..