echo off cls echo. echo this batch file executes PCSDL with predetermined settings/args echo. echo procedure for SDL: echo 1. prepare all necessary files echo 2. turn OFF the card to be SDL'ed echo 3. execute this bat file echo 4. turn ON the card to be SDL'ed rem Notes: rem 1. upon powering up, the viper will listen for SDL request sequence rem for about 2 seconds; it is likely that the card may have not received rem the SDL request, try a few times rem 2. if the 2 second period expired and there was no SDL request, the rem boot code will try to list all files exists on flash file sys rem In case of difficulties: rem 1. PCSDL requires HW flow control - insure that the serial cable supports it rem 2. check PC port for correct IRQ and such rem 3. it is likely that the card may have not received the SDL request, repeat rem step 2, 3, 4 rem assumptions: rem - curr dir contains: rem - PCSDL.EXE - PCSDL executable rem - va010000.sdl - PCSDL Agent rem - va010000.nac - combined code to download if not "%1"=="115" goto is_192 set BAUDRATE=115200 goto check_HW :is_192 if not "%1"=="192" goto is_384 set BAUDRATE=19200 goto check_HW :is_384 if not "%1"=="384" goto is_576 set BAUDRATE=38400 goto check_HW :is_576 if not "%1"=="576" goto is_24 set BAUDRATE=57600 goto check_HW :is_24 if not "%1"=="24" goto error_msg set BAUDRATE=2400 goto check_HW :check_HW if not "%2"=="56k" goto is_bri set TARGET=ld goto do_it :is_bri if not "%2"=="bri" goto is_da set TARGET=lb goto do_it :is_da if not "%2"=="da" goto is_v2 set TARGET=ll goto do_it :is_v2 if not "%2"=="v2" goto is_va set TARGET=v2 goto do_it :is_va if not "%2"=="va" goto error_msg set TARGET=va goto do_it :do_it echo. echo download TARGET=%TARGET% echo running pcsdl with port 1 at %BAUDRATE% echo. REM Unless you have a 16550AF UART, disable UART FIFO REM to enable UART FIFO remove the "-b" option REM REM Edit the pcsdl command line -v paramater so that it includes REM the REM version number of the NAC file. The version number of REM the NAC file is part of the filename. The filename syntax is: REM REM vaxxyyzz where xx = major version number REM yy = minor version number REM zz = revision number REM REM Release 1.0.10 would have a filename of va010008. REM REM REM Change the -p option on the pcsdl command line to use the REM proper COM port. pcsdl -p1 -r%BAUDRATE% -vNA1.0.10 -vSD1.0.2 -nSD%TARGET% -nNA%TARGET% goto done :error_msg echo. echo usage: dl [baud target] echo baud = 115, 115200, 576, 57600 OR 192, 19200 echo target = va :done rem Clear environment set TARGET= set BAUDRATE= echo on