[sane-devel] Learning about USB and scanners

Henning Meier-Geinitz henning at meier-geinitz.de
Mon Jan 2 15:10:16 UTC 2006


Hi,

On 2006-01-01 23:14, Stephen More wrote:
> I have a USB Visioneer Scanner that I would like to get working on Linux. So

Which scanner exactly?

> 4.  I am saving the output of usb_bulk_write to files

So the files mentioned below is the data that is sent to the scanner?
Or do you mean bulk_read?

> So far I am only scanning a B&W 9 pixel x 9 pixle area ...I am expexting an
> 81 byte file but I am getting much more than that.
> Can some one help me take this raw output and convert in into an image file
> I can view ?

Well, that depends on the format of that data :-)

Some general hints: If the scanner has a real black&white/lineart
mode, the size of the image data itsself can be even smaller
(something like 9 * ceil (9 / 8)).

If the scanner uses its gray mode, the minimum is 81 bytes. However,
the scanner may have a minimum size, so the driver may actually scan
more data (e.g. 1"x1", or 256 pixels at minimum, or similar).

Before you get scan data from the device you may receive calibration
data, which can be much bigger than the 9x9 pixel. E.g. Full lines at
full resolution, 16 bit/color.

Bye,
  Henning



More information about the sane-devel mailing list