home *** CD-ROM | disk | FTP | other *** search
/ back2roots/filegate / filegate.zip / filegate / ads / adsutils / EXSTSSCS.LHA / ExistsSCSIDEV.readme < prev    next >
Encoding:
Text File  |  2001-09-15  |  3.9 KB  |  98 lines

  1. Short:          Exists check for SCSI device.
  2. Author:       lars@rotebo.nl (Lars Van Jeurissen)
  3. Uploader:     lars@rotebo.nl (Lars Van Jeurissen)
  4. Version:      1.0
  5. Requires:     AmigaDOS 2.04+
  6. Type:          disk/misc
  7. Distribution: freely distributable
  8.  
  9.  
  10. The Purpose of this program is that you can check if you have your
  11. cdrom/scanner or other scsi device turned on. This program give a
  12. standard RETURN_OK or RETURN_FAIL/RETURN_WARN return value. Based on
  13. that you can perform some conditional actions, like mounting when the
  14. device is available, etc. I mount my devices from DEVS:DosDrivers, but
  15. when I forgot to turn my CDROM on I always got a lot of problems. So
  16. when I didn't want my CDROM to be mounted, I had to move the MountFile
  17. CD0 to SYS:Storage/DosDrivers. See the next snippet of my startup-sequence
  18. to get the general Idea of this program
  19.  
  20. snippet of my startup-sequence!
  21.  
  22. ExistsSCSIDEV DEVICE scsi.device UNIT 2 TYPE CDROM
  23. IF NOT WARN
  24.   Copy SYS1:Storage/DosDrivers/CD0 devs:DosDrivers QUIET
  25.   Copy SYS1:Storage/DosDrivers/CD0.info devs:DosDrivers QUIET
  26. EndIf
  27.  
  28. IF EXISTS SYS:Devs/DOSDrivers
  29.       Mount >NIL: SYS:Devs/DosDrivers/~(#?.info)
  30. EndIF
  31.  
  32. IF EXISTS Devs:DosDrivers/CD0
  33.   Delete Devs:DosDrivers/CD0 Devs:DosDrivers/CD0.info QUIET
  34. EndIf
  35.  
  36. Change Moumtfile name to the one you use, or if you mount directly
  37. from Mountlist you have to do the mounting where I do the copying.
  38.  
  39. Usage:
  40. ExistsSCSIDEV DEVICE/K,UNIT/K/N,TYPE/K,VERBOSE/S,HELP/S
  41.  
  42. Example:
  43. ExistsSCSIDEV DEVICE scsi.device UNIT 2 TYPE CDROM VERBOSE HELP
  44.  
  45. valid TYPEs are:
  46.      DIRECT, SEQUENTIAL,    PRINTER,        CPU,  WRITEONCE,      CDROM,
  47.     SCANNER, OPTICALMEM, MEDIUMCHGR,       COMM,    ASC1IT8,    ASC2IT8,
  48.   RESERVED1,  RESERVED2,  RESERVED3,  RESERVED4,  RESERVED5,  RESERVED6,
  49.   RESERVED7,  RESERVED8,  RESERVED9, RESERVED10, RESERVED11, RESERVED12,
  50.  RESERVED13, RESERVED14, RESERVED15, RESERVED16, RESERVED17, RESERVED18,
  51.  RESERVED19,    UNKNOWN,
  52.  
  53. VERBOSE gives out extra information. If you don't know what type your
  54. device is, you will get information about the type which was found.
  55.  
  56. SCSI-2 Compiliant Device           <-- SCSI-1 or SCSI-2 device type
  57. Wanted Device: CD-ROM device       <-- Description of the wanted device type
  58. Parsed Type Argument: CDROM        <-- Here you find the wanted device type
  59.  
  60. Actual Device Found: CD-ROM device <-- Description of the found device type
  61. Required Type Argument: CDROM      <-- Here you find the found device type
  62. SANYO   CRD-250S        Rev:1.19   <-- Inquiry Data from found device
  63.  
  64. I didn't do any programming on the Amiga for several years. I started
  65. looking at my Amiga a week ago. And I'm pleased with the ease of use and
  66. the clear way to program for the Amiga.
  67. I programmed almost a decade for the Windows environment, which is a very
  68. closed system. It is a shame that the Amiga didn't do better than it.
  69.  
  70.  
  71. This example is provided "as-is" and is subject to change; no
  72. warranties are made.  All use is at your own risk. No liability or
  73. responsibility is assumed.
  74.  
  75. Lars Van Jeurissen        09-16-2001
  76. De Wetstraat 13
  77. 6814 AN
  78. Arnhem
  79. The Netherlands
  80. lars@rotebo.nl
  81.  
  82. ============================= Archive contents =============================
  83.  
  84. Original  Packed Ratio    Date     Time    Name
  85. -------- ------- ----- --------- --------  -------------
  86.       40      40  0.0% 07-Sep-01 23:56:48  .info
  87.    24772   13218 46.6% 15-Sep-01 22:37:10  ExistsSCSIDEV
  88.    13810    4544 67.0% 15-Sep-01 22:34:22  ExistsSCSIDEV.c
  89.      835     394 52.8% 15-Sep-01 22:37:10  ExistsSCSIDEV.info
  90.    17586    3382 80.7% 15-Sep-01 22:37:14  ExistsSCSIDEV.map
  91.      837     316 62.2% 13-Sep-01 01:46:26  ExistsSCSIDEV.map.info
  92.      164     120 26.8% 15-Sep-01 23:20:26  ExistsSCSIDEV.readme
  93.      782     224 71.3% 11-Sep-01 03:43:28  ExistsSCSIDEV.testscript
  94.      513     250 51.2% 15-Sep-01 20:23:28  LMKFILE
  95.       54      46 14.8% 15-Sep-01 20:03:32  SASCOPTS
  96. -------- ------- ----- --------- --------
  97.    59393   22534 62.0% 15-Sep-101 23:22:06   10 files
  98.