sane-project-website/old-archive/2001-05/0042.html

218 wiersze
8.3 KiB
HTML

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"
"http://www.w3.org/TR/REC-html40/loose.dtd">
<HTML>
<HEAD>
<TITLE>sane-devel: Re: HP 7400c info / Minolta Scan Dual II</TITLE>
<META NAME="Author" CONTENT="Oliver Neukum (Oliver.Neukum@lrz.uni-muenchen.de)">
<META NAME="Subject" CONTENT="Re: HP 7400c info / Minolta Scan Dual II">
</HEAD>
<BODY BGCOLOR="#FFFFFF" TEXT="#000000">
<H1>Re: HP 7400c info / Minolta Scan Dual II</H1>
<!-- received="Thu May 3 02:42:04 2001" -->
<!-- isoreceived="20010503094204" -->
<!-- sent="Thu, 3 May 2001 11:51:04 +0200" -->
<!-- isosent="20010503095104" -->
<!-- name="Oliver Neukum" -->
<!-- email="Oliver.Neukum@lrz.uni-muenchen.de" -->
<!-- subject="Re: HP 7400c info / Minolta Scan Dual II" -->
<!-- id="01050311510400.02042@idun" -->
<!-- inreplyto="6e.a3b80a0.282275fc@aol.com" -->
<STRONG>From:</STRONG> Oliver Neukum (<A HREF="mailto:Oliver.Neukum@lrz.uni-muenchen.de?Subject=Re:%20HP%207400c%20info%20/%20Minolta%20Scan%20Dual%20II&In-Reply-To=&lt;01050311510400.02042@idun&gt;"><EM>Oliver.Neukum@lrz.uni-muenchen.de</EM></A>)<BR>
<STRONG>Date:</STRONG> Thu May 03 2001 - 02:51:04 PDT
<P>
<!-- next="start" -->
<LI><STRONG>Next message:</STRONG> <A HREF="0043.html">Ulrich Deiters: "Re: Canon backend"</A>
<UL>
<LI><STRONG>Previous message:</STRONG> <A HREF="0041.html">EdHamrick@aol.com: "Re: HP 7400c info / Minolta Scan Dual II"</A>
<LI><STRONG>In reply to:</STRONG> <A HREF="0041.html">EdHamrick@aol.com: "Re: HP 7400c info / Minolta Scan Dual II"</A>
<!-- nextthread="start" -->
<LI><STRONG>Next in thread:</STRONG> <A HREF="0052.html">EdHamrick@aol.com: "Re: HP 7400c info / Minolta Scan Dual II"</A>
<!-- reply="end" -->
<LI><STRONG>Messages sorted by:</STRONG>
<A HREF="date.html#42">[ date ]</A>
<A HREF="index.html#42">[ thread ]</A>
<A HREF="subject.html#42">[ subject ]</A>
<A HREF="author.html#42">[ author ]</A>
</UL>
<HR NOSHADE><P>
<!-- body="start" -->
<P>
On Thursday, 3. May 2001 10:51, you wrote:
<BR>
<EM>&gt; In a message dated 5/3/2001 3:19:34 AM EST, <A HREF="mailto:moitinho@civil.ist.utl.pt?Subject=Re:%20HP%207400c%20info%20/%20Minolta%20Scan%20Dual%20II&In-Reply-To=&lt;01050311510400.02042@idun&gt;">moitinho@civil.ist.utl.pt</A>
</EM><BR>
writes:
<BR>
<EM>&gt; &gt; I have read the arguments in favour of different drivers, you don't need
</EM><BR>
<EM>&gt; &gt; to try to explain, but I still don't understand why (for instance) the
</EM><BR>
<EM>&gt; &gt; usb-storage driver doesn't work (at least id didn't). Just my problem of
</EM><BR>
<EM>&gt; &gt; thinking that I understand what I don't.
</EM><BR>
<EM>&gt;
</EM><BR>
<EM>&gt; There's no good reason why a single driver shouldn't serve
</EM><BR>
<EM>&gt; as a scsi-&gt;usb device driver for all devices that need to look
</EM><BR>
<EM>&gt; like a scsi device to higher level routines.
</EM><BR>
<P>Our disagreement seems to be rather in the type of scanners that should
<BR>
appear as scsi devices to user space.
<BR>
If I understand Ed correctly, to him that would be all of them.
<BR>
<P><EM>&gt; Oliver claims this would be too hard to write, but I've done it
</EM><BR>
<EM>&gt; on Windows and Mac OS and it isn't hard. The upper levels
</EM><BR>
<EM>&gt; of VueScan think they're working with SCSI scanners, and
</EM><BR>
<EM>&gt; at the lowest level I translate scsi commands to USB
</EM><BR>
<EM>&gt; commands. The trick is to design the driver to do this from
</EM><BR>
<EM>&gt; the start. This works today on Windows and Mac OS with
</EM><BR>
<EM>&gt; HP, Epson, Avision, Acer, and AGFA USB scanners. I did
</EM><BR>
<EM>&gt; the same thing with Firewire scanners on Windows, since
</EM><BR>
<EM>&gt; they also encapsulate scsi commands on Firewire (SBP2
</EM><BR>
<EM>&gt; protocol). Someone already did a generic scsi-&gt;firewire
</EM><BR>
<EM>&gt; driver on Linux, and a similar scsi-usb driver is all that's needed.
</EM><BR>
<P>Firewire is a better design. There is no question about that.
<BR>
USB has no common protocol for transfering SCSI commands.
<BR>
In fact I know of _six_ incompatible protocols to do that.
<BR>
The attempt to unify them leads to a monster like usb-storage.
<BR>
I wanted to add the microtek protocol to usb-storage, but Matt vetoed that.
<BR>
<P><EM>&gt; Note that the advantage of using generic scsi-&gt;usb and
</EM><BR>
<EM>&gt; scsi-&gt;firewire drivers is that there isn't any need to set
</EM><BR>
<EM>&gt; up configuration files specifying which scanners (and
</EM><BR>
<EM>&gt; what type of scanners) are on the system. The nice
</EM><BR>
<EM>&gt; part of scsi is that it's possible to poll each device to find
</EM><BR>
<EM>&gt; out what kind of device it is, instead of depending on the
</EM><BR>
<EM>&gt; user to set this up (this is a lot more user-friendly). This
</EM><BR>
<EM>&gt; is how VueScan works.
</EM><BR>
<P>I could trivially merge microtek and hp5300 to a common driver.
<BR>
However there would still be the generic driver (scanner.c) and
<BR>
the two drivers currently under development for even stranger scanners.
<BR>
Reducing the number of drivers from 5 to 4 isn't IMHO worth the trouble.
<BR>
Unless you go to one, you need to look it up anyway, thus simplicity in
<BR>
kernel is more important.
<BR>
<P>As for configuration, loading a driver for your usb scanner is the same
<BR>
trouble as loading a driver for the controller your scsi scanner is attached
<BR>
to.
<BR>
After that for microtek and hp5300 then you can probe as for conventional
<BR>
scsi. Generic usb scanners are a problem though.
<BR>
<P><EM>&gt; This driver the kind of thing I'd assign a college intern or
</EM><BR>
<EM>&gt; beginning programmer to do - it's not hard. If nobody on
</EM><BR>
<EM>&gt; this list has any kernel programming experience, I'll do it
</EM><BR>
<EM>&gt; myself in a month or two as soon as I finish some higher
</EM><BR>
<EM>&gt; priority tasks in VueScan. However, if I write it, I plan to
</EM><BR>
<EM>&gt; sell it (it won't be open source). If someone wants to
</EM><BR>
<EM>&gt; write it and make it open source, I'd be happy to provide
</EM><BR>
<EM>&gt; them the technical assistance they'd need to get it working
</EM><BR>
<EM>&gt; with a wide range of usb scanners.
</EM><BR>
<P>For generic scanners you _could_ go the easy route.
<BR>
Emulate INQUIRY based on a table of vend./prod. ids and
<BR>
map read/write over usb to SCSI_READ/SCSI_WRITE.
<BR>
<P>It can be done. Even the unusual scanners could be handled with vendor
<BR>
specific commands. However at some point you end up with a scsi interpreter
<BR>
in kernel.
<BR>
The resulting driver would end up much more complicated than generic scanner,
<BR>
which is beautifully simple.
<BR>
I am quite convinced that it would not be accepted into the kernel, even be
<BR>
it open source.
<BR>
<P>What we need to solve is the problem of identifying usb device with a device
<BR>
node with IMHO a generic ioctl. And someone should sacrifice his keyboard for
<BR>
fixing autoloading for scanner.o
<BR>
<P>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Regards
<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Oliver
<BR>
<P><PRE>
--
Source code, list archive, and docs: <A HREF="http://www.mostang.com/sane/">http://www.mostang.com/sane/</A>
To unsubscribe: echo unsubscribe sane-devel | mail <A HREF="mailto:majordomo@mostang.com?Subject=Re:%20HP%207400c%20info%20/%20Minolta%20Scan%20Dual%20II&In-Reply-To=&lt;01050311510400.02042@idun&gt;">majordomo@mostang.com</A>
</PRE>
<P><!-- body="end" -->
<HR NOSHADE>
<UL>
<!-- next="start" -->
<LI><STRONG>Next message:</STRONG> <A HREF="0043.html">Ulrich Deiters: "Re: Canon backend"</A>
<LI><STRONG>Previous message:</STRONG> <A HREF="0041.html">EdHamrick@aol.com: "Re: HP 7400c info / Minolta Scan Dual II"</A>
<LI><STRONG>In reply to:</STRONG> <A HREF="0041.html">EdHamrick@aol.com: "Re: HP 7400c info / Minolta Scan Dual II"</A>
<!-- nextthread="start" -->
<LI><STRONG>Next in thread:</STRONG> <A HREF="0052.html">EdHamrick@aol.com: "Re: HP 7400c info / Minolta Scan Dual II"</A>
<!-- reply="end" -->
<LI><STRONG>Messages sorted by:</STRONG>
<A HREF="date.html#42">[ date ]</A>
<A HREF="index.html#42">[ thread ]</A>
<A HREF="subject.html#42">[ subject ]</A>
<A HREF="author.html#42">[ author ]</A>
</UL>
<!-- trailer="footer" -->
<HR NOSHADE>
<P>
<SMALL>
<EM>
This archive was generated by <A HREF="http://www.hypermail.org/">hypermail 2b29</A>
: <EM>Thu May 03 2001 - 02:42:50 PDT</EM>
</EM>
</SMALL>
</BODY>
</HTML>