[sane-devel] PATCH : Disallowing sane-find-scanner to detect Non-Scanner USB devices

Johannes Meixner jsmeix at suse.de
Wed Aug 9 08:44:04 UTC 2006


Hello,

On Aug 9 13:03 Parag N(????) wrote (shortened):
> With reference to Johannes Meixner's mail to this mailing list
> http://lists.alioth.debian.org/pipermail/sane-devel/2006-August/017446.html,
> I have created a patch that will make sane-find-scanner not to detect
> Non-Scanner USB devices.

The following in the patch looks wrong for me:
----------------------------------------------------------------
+                if (i->bInterfaceClass == 255)
+                    {
+                       --is_scanner;
----------------------------------------------------------------
because there are USB scanners which have bInterfaceClass = 255
e.g. my Epson all-in-one device, see my other mail where I
listed sane-find-scanner and lsusb results on three hosts:
----------------------------------------------------------------
Bus 002 Device 003: ID 04b8:080f Seiko Epson Corp. 
  bDeviceClass            0 (Defined at Interface level)
  idVendor           0x04b8 Seiko Epson Corp.
  idProduct          0x080f 
      bInterfaceClass       255 Vendor Specific Class
      iInterface              5 EPSON Scanner
      bInterfaceClass         7 Printer
      iInterface              6 USB Printer
      bInterfaceClass         8 Mass Storage
      iInterface              7 USB Mass Storage
----------------------------------------------------------------
and my plain Epson USB scanner has also bInterfaceClass = 255
----------------------------------------------------------------
Bus 001 Device 002: ID 04b8:0121 Seiko Epson Corp. 
  bDeviceClass          255 Vendor Specific Class
  idVendor           0x04b8 Seiko Epson Corp.
  idProduct          0x0121 
      bInterfaceClass       255 Vendor Specific Class
      iInterface              0 
----------------------------------------------------------------

Kind Regards,
Johannes Meixner
-- 
SUSE LINUX Products GmbH, Maxfeldstrasse 5      Mail: jsmeix at suse.de
90409 Nuernberg, Germany                    WWW: http://www.suse.de/



More information about the sane-devel mailing list