[sane-devel] "sane_read: Device busy" with Canon PIXMA MX310 and sane 1.0.20-4ubuntu3

Nicolas Martin nicolas0martin at gmail.com
Sat Nov 28 14:32:26 UTC 2009


After analysis: your log trace shows that Sane is compiled in Ubuntu
Karmic with the USE_PTHREAD/-lpthread support, which revealed a bug at
end of scan (not produced when pthread support is not activated).

Just committed a fix, so could you please give a try with git Sane, and
test both compilations options, with and without pthread support.

You can follow the guidelines here to compile and install Sane:
http://mp610.blogspot.com/2008/04/give-your-scanner-new-freshly-sane.html 

- To compile without pthread support, set firstly 2 export lines this:

make distclean
export CFLAGS=""
export LIBS=""

Then go on from the ./configure steps

When you run a scan after activating the log trace (as explained in a
previous mail), you should get in the log trace, a line like this near
the beginning:

[pixma] Reader task id=xxxx (forked)

- To compile with pthread support (this is the Ubuntu/Karmic way), set
first 2 export lines this:

make distclean
export CFLAGS="-DUSE_PTHREAD"
export LIBS="-lpthread"

Then go on from the ./configure steps

When you run a scan after activating the log trace, you should get in
the log trace, a line like this near the beginning:

[pixma] Reader task id=-xxxxxxxxxx (threaded)

In both cases, hopefully, the multi-page ADF scan should work correctly
now ;-)

Let us know.
Nicolas

Le mercredi 25 novembre 2009 à 21:44 +0100, Nicolas Martin a écrit :
> I'll take a look to the log trace and compare it to some others I have
> for multi-page ADF. 
> There's something abnormal at the end of the first scan page, which
> leads to the "Canceled by Software" condition after the first scanned
> page. Never saw it before, so will try to understand what produces that,
> and will keep you posted.
> 
> Probably will require a small change to the backend, so in the meantime,
> could you download, recompile and install the git Sane version, as I'll
> send you some patched file to be recompiled with the git version.
> 
> Nicolas
> 
> Le mardi 24 novembre 2009 à 23:55 +0100, Rogier Eggers a écrit :
> > Hi Nicolas,
> > 
> > Thanks for replying. Your debug instructions produced the attached log
> > file. I hope you can make something of it. 
> > 
> > Regards,
> > 
> > Rogier Eggers
> > 
> > 
> > On Tue, 2009-11-24 at 08:15 +0100, Nicolas Martin wrote: 
> > > Hi Rogier,
> > > 
> > > We would need first a log trace to see what's going on here, don't know
> > > what could have changed with Karmic. Could you run the scanimage batch
> > > command like this:
> > > 
> > > $ export SANE_DEBUG_PIXMA=11
> > > $ scanimage --batch --source="Automatic Document Feeder" -v -d
> > > "pixma:04A91728_1163AA" -v 1> test.tiff  2> scanimage.log
> > > 
> > > and send me back the scanimage.log file you'll get.
> > > 
> > > Nicolas
> > > 
> > > Le lundi 23 novembre 2009 à 23:40 +0100, Rogier Eggers a écrit :
> > > > Hello,
> > > > 
> > > > My scanner has trouble scanning multiple pages with the ADF. The
> > > > second consecutive page with scanimage always gives me the following
> > > > error:
> > > > 
> > > > scanimage: sane_read: Device busy
> > > > Scanned page 2. (scanner status = 3)
> > > > 
> > > > This happens with all sane interfaces/programs that I have installed
> > > > (xsane, scanimage from command line and gscn2pdf with all included
> > > > frontends). Interestingly, there is no problem with scanning one page
> > > > at a time (or scanning with the Flatbed). Documents do not get stuck
> > > > in the scanner as I can issue the exact same command again and the
> > > > next page (first page of that batch) will scan properly again.
> > > > 
> > > > It used to work several months ago. Help very much appreciated!
> > > > 
> > > > Earlier, I had a conversation on the gscan2pdf-help mailing list as I
> > > > first experienced the problem with that program, but understandably I
> > > > was referred to this list. See thread here:
> > > > http://sourceforge.net/mailarchive/forum.php?thread_name=20091030150312.GB4933%40eeepc&forum_name=gscan2pdf-help
> > > > 
> > > > Detail information:
> > > > 
> > > > Canon PIXMA MX310 (usb connected multi-functional device)
> > > > Ubuntu 9.10 Karmic
> > > > libsane 1.0.20-4ubuntu3
> > > > sane 1.0.14-7
> > > > sane-utils 1.0.20-4ubuntu3
> > > > 
> > > > Command and full output:
> > > > 
> > > > rogier at rogier-desktop:~$ scanimage --batch --source="Automatic
> > > > Document Feeder" -v -d "pixma:04A91728_1163AA" -v > test.tiff
> > > > Scanning -1 pages, incrementing by 1, numbering from 1
> > > > Scanning page 1
> > > > scanimage: scanning image of size 640x877 pixels at 24 bits/pixel
> > > > scanimage: acquiring RGB frame
> > > > scanimage: min/max graylevel value = 22/255
> > > > scanimage: read 1683840 bytes in total
> > > > Scanned page 1. (scanner status = 5)
> > > > Scanning page 2
> > > > scanimage: scanning image of size 640x877 pixels at 24 bits/pixel
> > > > scanimage: acquiring RGB frame
> > > > scanimage: min/max graylevel value = 255/0
> > > > scanimage: sane_read: Device busy
> > > > Scanned page 2. (scanner status = 3)
> > > > Closing device
> > > > Calling sane_exit
> > > > scanimage: finished
> > > > rogier at rogier-desktop:~$
> > > > 
> > > > 
> > > > Thanks & Regards,
> > > > 
> > > > Rogier Eggers 
> > > > --
> > > > sane-devel mailing list: sane-devel at lists.alioth.debian.org
> > > > http://lists.alioth.debian.org/mailman/listinfo/sane-devel
> > > > Unsubscribe: Send mail with subject "unsubscribe your_password"
> > > >              to sane-devel-request at lists.alioth.debian.org
> > > 
> > 




More information about the sane-devel mailing list