[sane-devel] Insights from a newbie backend writer...
Earle F. Philhower, III
Sun, 10 Apr 2005 22:59:27 -0700 (PDT)
Don't give up yet, some suggestions you probably already heard below...
--- Fred Odendaal <email@example.com> wrote:
> So, I'm thinking "I've got a degree in comp. sci. How difficult can it
> be to write a scanner driver?"
> Finally after many Windows scans and log files at various different
> sizes, resolutions, and colour or gray scale mode I start writing the
> backend. It only took me about 2 weeks before I could scan on Linux, but
> this is the easy part! What I soon discovered is something called
> CALIBRATION. At 600x1200dpi colour resolution the Windows driver
> actually does ~20 scans off to the side of the glass flat bed. I have no
> idea what its doing. By looking at the usb logs it appears to be setting
> the gain and the dc offset in a gradual fashion over several calibration
Dump the received binary data to an image and then just see which
control register they're iterating over. Then it's just a matter of
figuring what they want the end image to look like (ie. adjust offset
down until black pixels are < XXX, then increase gains until white
pixels are near YYY). The received calibration image was really helpful
when I was trying to figure out what the heck the Microtek driver
It may also be adjusting the individual pixel gains for each sensor
element. If there's a really large download of slowly varying #s
between scans that might be a pointer.
Do you Yahoo!?
Make Yahoo! your home page