home *** CD-ROM | disk | FTP | other *** search
/ Boot Disc 8 / boot-disc-1997-04.iso / PDA_Soft / Psion / comms / rcom114 / DOSSETUP.BAT < prev    next >
DOS Batch File  |  1994-10-12  |  3KB  |  124 lines

  1. @echo off
  2. if not exist \dos\sys$rpcs.img goto disk_bad
  3. if (%1)==() goto xhelp
  4. if (%1)==(?) goto xhelp
  5. if (%1)==(-h) goto xhelp
  6. if (%1)==(/h) goto xhelp
  7. if (%1)==(/help) goto xhelp
  8. if (%1)==(help) goto xhelp
  9.  
  10. set _xpth=%1
  11. if not %_xpth%==%1 goto env_full
  12. \dos\rmkdir %_xpth%
  13. \dos\rmkdir %_xpth%\rtf
  14. \dos\rmkdir %_xpth%\printdrv
  15. \dos\rmkdir %_xpth%\scr
  16. \dos\rmkdir %_xpth%\opl
  17. set _xpsi=s3a
  18. if not %_xpsi%==s3a goto env_full
  19. set _xprt=com1
  20. if not %_xprt%==com1 goto env_full
  21. goto parm_top
  22.  
  23. :set_mach
  24. set _xpsi=%1
  25. goto parm_top
  26.  
  27. :set_com
  28. set _xprt=%1
  29.  
  30. :parm_top
  31. shift
  32. if "%1"=="" goto copy_it
  33. if "%1"=="s3" goto set_mach
  34. if "%1"=="s3a" goto set_mach
  35. if "%1"=="hc" goto set_mach
  36. if "%1"=="mc" goto set_mach
  37. if "%1"=="S3" goto set_mach
  38. if "%1"=="S3A" goto set_mach
  39. if "%1"=="HC" goto set_mach
  40. if "%1"=="MC" goto set_mach
  41. if "%1"=="com1" goto set_com
  42. if "%1"=="com2" goto set_com
  43. if "%1"=="com3" goto set_com
  44. if "%1"=="com4" goto set_com
  45. if "%1"=="COM1" goto set_com
  46. if "%1"=="COM2" goto set_com
  47. if "%1"=="COM3" goto set_com
  48. if "%1"=="COM4" goto set_com
  49. echo DOSSETUP does not understand this parameter:  %1
  50. echo.
  51. goto xhelp
  52.  
  53. :copy_it
  54. echo.
  55. echo Installing files to:  %_xpth%
  56. echo Psion machine:  %_xpsi%
  57. echo Serial port:  %_xprt%
  58. echo.
  59. echo Press Control-C if any of these settings are incorrect.
  60. echo Press any other key to continue with the installation.
  61. pause>NUL
  62.  
  63. copy \dos\rcom.exe %_xpth%>NUL
  64. copy \dos\rcom.rsc %_xpth%>NUL
  65. copy \dos\sys$rpcs.img %_xpth%>NUL
  66. copy \dos\sys$tycl.pdd %_xpth%>NUL
  67. copy \dos\autorcom.bat %_xpth%>NUL
  68. copy \dos\rbackup.bat %_xpth%>NUL
  69. copy \dos\rtfinst.bat %_xpth%>NUL
  70. copy \rprint\rprint.exe %_xpth%>NUL
  71. copy \rprint\prinst.bat %_xpth%>NUL
  72. copy \rtf\*.* %_xpth%\rtf>NUL
  73. copy \printdrv\*.* %_xpth%\printdrv>NUL
  74. copy \scr\*.* %_xpth%\scr>NUL
  75. copy \opl\*.* %_xpth%\opl>NUL
  76.  
  77. rem some temporary protection against the root directory
  78. if %_xpth%==c:\ set _xpth=c:
  79. if %_xpth%==d:\ set _xpth=d:
  80. if %_xpth%==e:\ set _xpth=e:
  81.  
  82. copy \dos\rcom%_xpsi%.ini %_xpth%\rcom.ini>NUL
  83. copy \dos\rbak%_xpsi%.bat %_xpth%\bak.bat>NUL
  84. echo Physical=%_xprt%>>%_xpth%\rcom.ini
  85. echo.
  86. echo RCOM installed.
  87. goto end
  88.  
  89. :env_full
  90. echo Your MS-DOS "environment" is full.
  91. echo Remove one or more environment variables, then try again.
  92. echo Check your MS-DOS manual for more details of how to do this.
  93. goto end
  94.  
  95. :disk_bad
  96. echo You cannot run DOSSETUP from a different drive or directory.
  97. echo Change to the disk and directory containing DOSSETUP - eg type:
  98. echo     A:
  99. echo     CD\
  100. echo then:
  101.  
  102. :xhelp
  103. echo Type DOSSETUP followed by the directory on your hard disk to
  104. echo install the software into - for example:
  105. echo     DOSSETUP C:\PSRCOM
  106. echo This will install RCOM ready to run at a speed of 19,200 Baud (which
  107. echo is suitable for the Series 3a) and using the serial port COM1.
  108. echo.
  109. echo You can, if you wish, change these settings when you run DOSSETUP,
  110. echo by typing:
  111. echo     *) the name of your Psion computer ("S3A", "S3", "HC" or "MC");
  112. echo AND/OR
  113. echo     *) the PC serial port your Psion computer is attached to
  114. echo        ("COM1", "COM2", "COM3" or "COM4").
  115. echo For example, you might type:
  116. echo     DOSSETUP C:\PSRCOM S3 COM2
  117. echo or
  118. echo     DOSSETUP C:\RCOM COM3
  119. :end
  120. set _xpth=
  121. set _xpsi=
  122. set _xprt=
  123.  
  124.