@echo off
@rem Revision History
@rem Added preservation of Baseboard Part Number (PBA) which may now be
@rem  programmed during manufacturing (like baseboard serial number)

:restart
if %1.==SKIP. goto domenu
rem Display something to let them know we're working
cls
echo.Please wait...

rem Set initial environment variables
set BDSER=????????
set SESER=????????
call setdenv.bat

chkmode
if errorlevel 1 goto doloop

:domenu

cls
echo.              Update Disk %DSKVER%
if exist btm.rom del btm.rom
if exist oemb1.bin del oemb1.bin

if not exist platb1.bin goto nob1
 phlash /MFG /EXIT /B=platb1.bin /RO=oemb1.bin
 if errorlevel 1 goto error
:nob1

if not exist platbf.bin goto nobf
 phlash /MFG /EXIT /B=platb1.bin /RO=oemb1.bin
 if errorlevel 1 goto error
:nobf

if not exist platop6.bin goto noop6
 phlash /MFG /EXIT /B=platop6.bin /RO=btm.rom
 if errorlevel 1 goto error
 
:noop6
if not exist platop8.bin goto noop8
 phlash /MFG /EXIT /B=platop8.bin /RO=btm.rom

:noop8

if not exist platfbd.bin goto exit
 phlash /MFG /EXIT /B=platfbd.bin /RO=bios.rom

:exit
echo.
echo.Now remove floppy from drive and reboot.
echo.
:doloop
pause >nul
goto restart

:error
	echo.Batch file error. Please consult support engineer.

