[sane-devel] PIXMA: MX360 at 2400 x 1200 dpi

Rolf Bensch rolf at bensch-online.de
Mon Feb 13 17:08:07 UTC 2012

Am 10.02.2012 13:42, schrieb ibu ☉ radempa ䷰:
> Thanks. When I disable pixel_reordering analogously to MP220, then up to
> 1200 dpi gray and color scans are ok. At 2400 dpi however nothing is
> scanned and I get
> [pixma] read_image():reader task closed the pipe:0 bytes received,
> 143238656 bytes expected
> which comes from pixma.c; more specifically, this line produces count=0:
> count = read (ss->rpipe, buf, size);
> read_image() is called from sane_read(), which provides ss ("sane
> status", I guess) and itself gets it from a SANE_Handle which comes from
> the frontend, AFAIS. I don't understand enough of the internals of sane
> to know where to start debugging. - Hints are welcome.

You need to investigate 2 things:
(1) 1200 x 1200 dpi:
(a) Does the scaned image contain all expected pixels (w x h)?
(b) Please check the pnm image for mixed columns. It seems that two half 
pictures are bitwise mixed. The result is a streched image with a shadow 
of the 2nd half picture.  It's easy to solve this line by line with a 
(new) reorder_pixels function. You can have a look to similar functions 
in the pixma_mp810.c file.

(2) 2400 x 1200 dpi:
Here we should take care that the scanner gets the correct formatted 
scan command.
Can you sniff the usb protocols on a windows machine and compare it with 
one from a linux machine? Both for 2400 x 1200 dpi. The positions of the 
parameters can be read from the send_scan_param function. You can use 
e.g. wireshark for sniffing. The scan command starts with "d8 20 00 00 
00 00 00 00 00 00 00 00 00 00 00 38".


More information about the sane-devel mailing list