A snippet of a script I use to copy Backup Exec System Recovery files to a USB drive that gets rotated offsite once a week. Sometimes the USB drive might get mounted onto the next drive letter, especially, if the user plugs in the second drive before taking off the first drive. This script will check 2 drive letters. It could be easily altered to check as many drive letters as you like.
DATE /T >>d:batchcopyBESR.log
TIME /T >>d:batchcopyBESR.log
REM wakeup the USB drives
dir h:
dir g:
REM Assume USB drive to copy to is on H: if not then G:
SET DR=H
IF EXIST %DR%:test.txt GOTO begin
REM See if it is a new USB drive with no test file
ECHO test > %DR%:test.txt
IF EXIST %DR%:test.txt GOTO begin
REM Not on first drive check now check next drive
SET DR=G
IF EXIST %DR%:test.txt GOTO begin
ECHO test > %DR%:test.txt
IF EXIST %DR%:test.txt GOTO begin
REM No USB drives found on drive letters
d:batchemail "Can't find USB drive for BE System Recovery Copy" d:batchcopyBESR.log
GOTO end
:begin
robocopy e:srecovery %DR%:srecovery *.* /MIR /NP /R:3 /w:5 >>d:batchcopyBESR.log
DATE /T >>d:batchcopyBESR.log
TIME /T >>d:batchcopyBESR.log
d:batchemail "BE System Recovery Copy log" d:batchcopyBESR.log
:end