[sane-devel] Scanning produces black images

JKD jkdsoft at gmail.com
Mon Apr 16 15:12:20 UTC 2007

El Mon, 16 de Apr de 2007, a las 02:50:01PM +0200, Gerhard Jaeger dijo:
> On Montag, 16. April 2007, JKD wrote:
> > > This is also an issue with the Plustek backend, reported by various
> > > Ubuntu and Gentoo users. As already stated by PhobosK, the problem is
> > > the kernel option CONFIG_USB_SUSPEND. This in deed is needed for laptop
> > > users. It is currently marked as "experimental" but already used by various
> > > distros. 
> > > 
> > 
> > That was my first thought. But if it's a kernel problem neither xsane
> > nor scanimage would scan successfully. And in two different compilations of
> > hp3900, ubuntu's one fails and my last compilation works.
> > 
> > > I think the problem really is, that libusb does not know anything about that
> > > suspend stuff and therefore we have more or less no possibility to wakeup
> > > the port, where the scanner is connected to.
> > 
> > I think you're right. But may be libusb is already updated in debian
> > unstable. That would explain that my compilation works in ubuntu and
> > library provided by ubuntu in libsane-extras package doesn't. So my
> > conclusion would be the same. Backends need to be compiled against
> > current version of libusb.
> Could you please check which version of the libusb you/they use?

 libusb-0.1-4      0.1.12-6
 libusb-dev        0.1.12-6

 libusb-0.1-4      0.1.12-2
 libusb-dev        0.1.12-2

> > > One thing that could be observed: In all cases, scanimage works fine - guess
> > > this is because it never closes the port until the scan process is done.
> > 
> > I'm confused. Why should exist any difference between scanimage and xsane when
> > both frontends use the same SANE API to access usb scanners?
> Guess it's the workflow. When you call scanimage, then the scanner is openend,
> detected, configured, scanning is done, closed.
> XSane tries to open and detect, then closes a device. Then then scan is done
> upon request. And I think after the first close, the device (or the port) will
> be suspended.

I've compiled SANE backends in ubuntu. Instead of installing all project
I've just overwritten libsane-hp3900.la and libsane-hp3900.so.1.0.18 in
/usr/lib/sane with the ones generated in this compilation and xsane
works retrieving scanned image without problems.

Jonathan Bravo Lopez

More information about the sane-devel mailing list