dialog 4
Load Shadow (Get Password)
Load Flash File
Write Flash
Exit
begin:
option 1 ldshadow 2 ldflash 3 program 4 end
ldshadow:
echo Load shadow file
ldram shadow
getpw
goto continue
ldflash:
echo Load Flash file
ldram flash
goto continue
program:
confirmdlg
if CONFIRM == 0
goto continue
endif
if DEBUG == 0 
detect
wait 2000
if DEBUG == 0
echo Please try again
goto continue
endif 
endif 
echo Write Flash
erase flash
sprogram flash
cmpram flash
if CMPRAM == 0
echo Please power off/on the ECU and try again
endif
goto continue
continue:
goto begin
end:
