diff options
Diffstat (limited to 'doc/sane-scsi.man')
-rw-r--r-- | doc/sane-scsi.man | 107 |
1 files changed, 67 insertions, 40 deletions
diff --git a/doc/sane-scsi.man b/doc/sane-scsi.man index 5a27555..9239250 100644 --- a/doc/sane-scsi.man +++ b/doc/sane-scsi.man @@ -11,15 +11,15 @@ appropriate backend configuration file before using SANE for the first time. For most systems, the configuration file should list the name of the generic SCSI device that the scanner is connected to (e.g., under Linux, -.B /dev/sg4 +.I /dev/sg4 or -.B /dev/sge +.I /dev/sge is such a generic SCSI device). It is customary to create a symlink from -.B /dev/scanner +.I /dev/scanner to the generic SCSI device that the scanner is connected to. In this case, the configuration file simply lists the line -.BR /dev/scanner . +.IR /dev/scanner . For a detailed description of each backend's configuration file, please refer to the relevant backend manual page (e.g., .BR sane\-epson (5) @@ -46,7 +46,8 @@ is the SCSI model string, .I TYPE is type SCSI device type string, .I BUS -is the SCSI bus number (named "host" in /proc/scsi/scsi), +is the SCSI bus number (named "host" in +.IR /proc/scsi/scsi ), .I CHANNEL is the SCSI channel number, .I ID @@ -56,8 +57,9 @@ is the logical unit number of the scanner device. The first two fields are strings which must be enclosed in double-quotes if they contain any whitespace. The remaining four fields are non-negative integer numbers. The correct values for these fields can be found by using operating system -specific tools, e.g. for Linux by looking at the output of the command "cat -/proc/scsi/scsi". To simplify configuration, a field's value can be replaced +specific tools, e.g. for Linux by looking at the output of the command +.IR "cat /proc/scsi/scsi" . +To simplify configuration, a field's value can be replaced with an asterisk symbol (``*''). An asterisk has the effect that any value is allowed for that particular field. This can have the effect that a single scsi-line matches multiple devices. When this happens, each matching device @@ -103,11 +105,13 @@ form. This is explained below in the relevant platform-specific section. .PP When using a SCSI scanner, ensure that the access permission for the generic SCSI device is set appropriately. We recommend to add a group -"scanner" to /etc/group which contains all users that should have +"scanner" to +.I /etc/group +which contains all users that should have access to the scanner. The permission of the device should then be set to allow group read and write access. For example, if the scanner is at generic SCSI device -.BR /dev/sg0 , +.IR /dev/sg0 , then the following two commands would set the permission correctly: .PP .RS @@ -118,7 +122,7 @@ $ chmod 660 /dev/sg0 .RE .PP When your system uses the device filesystem (devfs), you have to edit -.BR /etc/devfs/perms. +.BIR /etc/devfs/perms. There you should search the line .PP .RS @@ -133,10 +137,13 @@ REGISTER ^sg4 PERMISSIONS root.scanner 0660 .PP .SH FREEBSD INFO Auto-configuration using the "scsi *" lines in the config files only works if -the user running the frontend has read/write access to /dev/xpt0. Instead, you -can also set a link +the user running the frontend has read/write access to +.IR /dev/xpt0 . +Instead, you can also set a link .I /dev/scanner -to the appropriate /dev/uk device. +to the appropriate +.I /dev/uk +device. .RS .TP Adaptec AHA1542CF @@ -162,11 +169,13 @@ Works on FreeBSD 2.2.5R and 3.0 using the driver, provided that Plug-and-Play support is disabled on the card. If there are no .I uk -devices, just do a ``sh MAKEDEV uk0'' in the -.B /dev +devices, just do a +.I sh MAKEDEV uk0 +in the +.i /dev directory. The scanner should then be accessible as -.B /dev/uk0 if it was probed -during boot. +.I /dev/uk0 +if it was probed during boot. .TP Tekram DC390 Reported to work fine under FreeBSD 2.2.2R with the @@ -176,23 +185,28 @@ driver. .SH LINUX INFO First, make sure your kernel has SCSI generic support enabled. In -``make xconfig'', this shows up under ``SCSI support->SCSI generic -support''. +.IR "make xconfig" , +this shows up under ``SCSI support->SCSI generic support''. .PP To keep scanning times to a minimum, it is strongly recommended to use a large buffer size for the generic SCSI driver. From SG driver version 2.0 on, the maximum buffer size can be changed at program run time, and there is no restriction in size. This driver version is part of the Linux kernels from version 2.2.7 on. If the new SG driver is available some backends -(e.g. sane\-umax, sane\-mustek, sane\-sharp) automatically request larger scsi -buffers. If a backend does not automatically request a larger scsi buffer, set +(e.g. +.BR sane\-umax (5), +.BR sane\-mustek (5) , +.BR sane\-sharp (5)) +automatically request larger SCSI +buffers. If a backend does not automatically request a larger SCSI buffer, set the environment variable .B SANE_SG_BUFFERSIZE to the desired buffer size in bytes. It is not recommended to use more than 1 MB, because for large values the probability increases that the SG driver cannot allocate the necessary buffer(s). For ISA cards, even 1 MB might be a too large value. For a detailed discussion of memory -issues of the SG driver, see http://www.torque.net/sg. +issues of the SG driver, see +.I http://www.torque.net/sg. .PP For Linux kernels before version 2.2.7 the size of the buffer is only 32KB. This works, but for many cheaper scanners this causes scanning to be slower by @@ -209,7 +223,7 @@ necessary with older Linux kernels. .PP A common issue with SCSI scanners is what to do when you booted -the system while the scanner was turned off? In such a case, the +the system while the scanner was turned off. In such a case, the scanner won't be recognized by the kernel and SANE won't be able to access it. Fortunately, Linux provides a simple mechanism to probe a SCSI device on demand. Suppose you have a scanner connected @@ -232,7 +246,9 @@ list isn't complete, usually any SCSI adapter supported by Linux should work. .RS .TP Acard/Advance SCSI adapters -Some old versions of the kernel driver (atp870u.c) cut the inquiry information. +Some old versions of the kernel driver +.RI ( atp870u.c ) +cut the inquiry information. Therefore the scanner couldn't be detected correctly. Use a current kernel. .TP Adaptec AHA-1505/AHA-1542/AHA-2940 @@ -259,12 +275,16 @@ NCR/Symbios 53c400/53c400a or Domex DTC3181E/L/LE (DTCT436/436P) ISA SCSI card This card is supplied by Mustek (and other vendors). It's supported since Linux 2.2. The SCSI cards are supported by the module g_NCR5380. It's necessary to tell the kernel the io port and type of card. Example for a -53c400a: ``modprobe g_NCR5380 ncr_addr=0x280 ncr_53c400a=1''. Once the kernel -detects the card, it should work all right. However, while it should work, do -not expect good performance out of this card---it has no interrupt line and -therefore while a scan is in progress, the system becomes almost unusable. -You may change the values of the USLEEP macros in drivers/scsi/g_NCR5380.c. -Some documentation is in this file and NCR5380.c. +53c400a: +.I "modprobe g_NCR5380 ncr_addr=0x280 ncr_53c400a=1" . +Once the kernel detects the card, it should work all right. +However, while it should work, do not expect good performance out of this +card---it has no interrupt line and therefore while a scan is in progress, +the system becomes almost unusable. You may change the values of the USLEEP +macros in +.IR drivers/scsi/g_NCR5380.c . +Some documentation is in this file and +.IR NCR5380.c . .TP NCR/Symbios 810 For some scanners it may be necessary to disable disconnect/reconnect. To @@ -275,16 +295,22 @@ both if you have trouble. For Linux kernels before 2.0.33 it may be necessary to increase the SCSI timeout. The default timeout for the Linux kernels before 2.0.33 is 10 seconds, which is way too low when scanning large area. If you get messages -of the form ``restart (ncr dead ?)'' in your /var/log/messages file or on the -system console, it's an indication that the timeout is too short. In this -case, find the line ``if (np->latetime>10)'' in file ncr53c8xx.c (normally in -directory /usr/src/linux/drivers/scsi) and change the constant 10 to, say, 60 -(one minute). Then rebuild the kernel/module and try again. +of the form ``restart (ncr dead ?)'' in your +.I /var/log/messages +file or on the system console, it's an indication that the timeout is too short. +In this case, find the line ``if (np->latetime>10)'' in file +.I ncr53c8xx. +(normally in directory +.IR /usr/src/linux/drivers/scsi ) +and change the constant 10 to, say, 60 (one minute). +Then rebuild the kernel/module and try again. .TP Tekram DC315 -The driver can be downloaded from http://www.garloff.de/kurt/linux/dc395/. +The driver can be downloaded from +.IR http://www.garloff.de/kurt/linux/dc395/ . For some older scanners it may be necessary to disable all the more advanced -features by using e.g. modprobe dc395x_trm dc395x_trm=7,5,1,32. +features by using e.g. +.IR "modprobe dc395x_trm dc395x_trm=7,5,1,32" . .TP Tekram DC390 Version 1.11 of the Tekram driver seems to work fine mostly, except @@ -295,16 +321,17 @@ and does not suffer from the timeout problems. .SH SOLARIS, OPENSTEP AND NEXTSTEP INFO Under Solaris, OpenStep and NeXTStep, the generic SCSI device name refers to a SCSI bus, not to an individual device. For example, -.B /dev/sg0 +.I /dev/sg0 refers to the first SCSI bus. To tell SANE which device to use, append the character 'a'+target-id to the special device name. For example, the SCSI device connected to the first SCSI controller and with target-id 0 would be called -.BR /dev/sg0a , +.IR /dev/sg0a , and the device with target-id 1 on that same bus would be called -.BR /dev/sg0b, +.IR /dev/sg0b, and so on. + .SH ENVIRONMENT .TP .B SANE_DEBUG_SANEI_SCSI |