[sane-devel] Question on SCSI-scanners
adeuring at gmx.net
Tue Jan 6 16:49:56 UTC 2009
On 06.01.2009 17:30, Dieter Jurzitza wrote:
> Dear listmembers,
> prior to doing a "deep down" search on my own, here's a question someone might
> be able to answer to me:
> The move in openSUSE from "conventional" permission distribution to hal
> recently started caused issues with SCSI scanners.
> By the help of the hal-developers I found a workaround that might require a
> certain extension to really work reliably.
> Therefore I'd like to know whether there is a chance to find from the sources
> (i. e. a specific variable there) whether a scanner announces itself
> as "processor", as "scanner" or as something else. This depends on the
> scsi.type that can be found in the device's bios.
> Any help would be greatly appreciated.
I think there is no other way than to look into the source code of
backends for SCSI scanners... IIRC only some Epson and HP scanners
present themselves as "processors", all others say that they are of type
"scanner". You can look if a backend checks for the SCSI device type
after having issued the INQUIRY command, or you can look in the
sane_start function. If the backend issues the SCSI commands 0x1b (start
scan) and 0x24 (set window), chances are goog that the device resents
itself as a scanner, not a processor.
But as I understand it, you need a list of SCSI vendor/model name
strings for HAL (or udev?) to configure some rules which devices should
be directly accessible for users. The most simple approach would be to
parse all *.desc files. This way you will not only get "processor" type
devices but also all those SCSI scanners that have the SCSI type
"scanner", but the list is not too long, I think. And I don't think that
SCSI scanners are any longer manufactured, so we have quite stable list
of these devices.
More information about the sane-devel