[sane-devel] genesys backend

Pierre Willenbrock pierre at pirsoft.dnsalias.org
Fri Sep 23 21:33:44 UTC 2005


Hi

I spent some time on fixing the last few bugs in the gl841 part known to
me and preparing the backend for the final inclusion of gl841 support
needed for my scanner.


The attached patch primarily adds yet another shading calibration
method, using the black and white strips at the top of the scanning
area. It also adds support for led exposure calibration needed for cis
scanners and instant power saving features.

The latter is needed because my scanner uses some gpio to completely
shut down some circuits like motor drivers and led drivers. The function
slot is called from sane_start and sane_cancel, as these seem to be the
functions at the begin and end of each scan. The version in the patch
mainly shuts down the afe.

The patch is not a full patch to get a Canon LiDE 35/50 scanner to work.
There is a patch on my private webspace which does that(see below).


Regarding the problem of the scanner not delivering any data i found
that it's only a problem of the first read after opening the scanner. So
my solution is to prepare a simple one line read, setting the usb
timeout to 1 second and then read, without checking the result(timeout
is reset to 30s afterwards). If the transmission fails, the scanner will
still think it succeeded, and later reads will work.

It is not clear to me why the scanner sometimes missends the first bulk
transfer originated from the scanner, but i suspect a bad usb
transmission, although the transfer does not generate any log messages.


I tried to implement real lineart, and got it to work most of the time.
It was a matter of setting the scanner to do lineart and then simply
pass the data on to the frontend, inverting all bits. There are still
some combinations of settings which may lead to a failed scan, as there
are some more complicated things still missing(stagger correction, line
shrinking).

Powersaving for the Canon LiDE 35(and hopefuly LiDE 50) works now, too.
I don't know if it is complete, but i could not measure a difference
between the scanner just plugged in and after a scan. My measuring
method was rather inaccurate, so i may be missing something.


As always a full patch to get Canon LiDE 35/50 to work can be found
here(will be updated to match experimental cvs):
http://www.pirsoft-dsl-dropzone.de/genesys_gl841.diff.bz2

It is now ready to be extensively tested. I guess using lineart will
reveal some problems, as mentioned above. But i stress tested the color
and gray modes to some extend using xsane and zooming the preview.


Regards,
  Pierre
-------------- next part --------------
A non-text attachment was scrubbed...
Name: genesys_calibration.diff.gz
Type: application/x-gzip
Size: 6525 bytes
Desc: not available
Url : http://lists.alioth.debian.org/pipermail/sane-devel/attachments/20050923/1a0204aa/genesys_calibration.diff.bin


More information about the sane-devel mailing list