Re: [sane-devel] [PATCH] canon_dr: Add support for batch count
Hi Vadim, Thanks for the patch. @Allan> Since you're listed as the canon_dr backend's author, can you take a look at this? Vadim V. Vlasov writes: > The patch adds support for batch count by introducing "--batchMode=XX" > parameter. This works at least with Canon DR-G1100 but may also > work with other scanners. At least it should not break current > behaviour (as long as you do not use "--batchMode=XX"). > Note, what you call "SSM2_BUFF_sync" is, probably, page count > rather than "sync (unbuffered) mode". > > diff -rup a/backend/canon_dr.c b/backend/canon_dr.c > --- a/backend/canon_dr.c2017-08-09 18:50:33.725500231 +0300 > +++ b/backend/canon_dr.c2017-08-09 19:16:42.073500044 +0300 > @@ -830,6 +830,7 @@ attach_one (const char *device_name, int > s->padded_read = global_padded_read; > s->extra_status = global_extra_status; > s->duplex_offset = global_duplex_offset; > + s->batchmode = 1; > > /* copy the device name */ > strcpy (s->device_name, device_name); > @@ -2540,6 +2541,18 @@ sane_get_option_descriptor (SANE_Handle >opt->cap = SANE_CAP_INACTIVE; > } > > + /*batch count*/ > + if(option==OPT_BATCHMODE){ > +opt->name = "batchMode"; > +opt->title = "Batch count"; > +opt->desc = "Request scanner to batch-scan N pages"; > +opt->type = SANE_TYPE_INT; > +if (s->has_buffer) > + opt->cap = SANE_CAP_SOFT_SELECT | SANE_CAP_SOFT_DETECT | > SANE_CAP_ADVANCED; > +else > + opt->cap = SANE_CAP_INACTIVE; > + } > + > if(option==OPT_SIDE){ > opt->name = "side"; > opt->title = "Duplex side"; > @@ -2914,6 +2927,10 @@ sane_control_option (SANE_Handle handle, > *val_p = s->buffermode; > return SANE_STATUS_GOOD; > > +case OPT_BATCHMODE: > + *val_p = s->batchmode; > + return SANE_STATUS_GOOD; > + > case OPT_SIDE: > *val_p = s->side; > return SANE_STATUS_GOOD; > @@ -3235,6 +3252,13 @@ sane_control_option (SANE_Handle handle, > > case OPT_BUFFERMODE: > s->buffermode = val_c; > + s->batchmode = !s->buffermode; > + return SANE_STATUS_GOOD; > + > +case OPT_BATCHMODE: > + s->batchmode = val_c; > + if (val_c != 1) > +s->buffermode = 1; > return SANE_STATUS_GOOD; > > } > @@ -3313,7 +3337,7 @@ ssm_buffer (struct scanner *s) > memset(out,0,outLen); > set_SSM2_BUFF_unk(out, !s->buffermode); > set_SSM2_BUFF_unk2(out, 0x40); > -set_SSM2_BUFF_sync(out, !s->buffermode); > +set_SSM2_BUFF_sync(out, s->batchmode); > > ret = do_cmd ( > s, 1, 0, > diff -rup a/backend/canon_dr.h b/backend/canon_dr.h > --- a/backend/canon_dr.h2017-08-09 18:50:33.725500231 +0300 > +++ b/backend/canon_dr.h2017-08-09 18:51:07.021500227 +0300 > @@ -48,6 +48,7 @@ enum scanner_Option > OPT_DROPOUT_COLOR_F, > OPT_DROPOUT_COLOR_B, > OPT_BUFFERMODE, > + OPT_BATCHMODE, > OPT_SIDE, > > /*sensor group*/ > @@ -280,6 +281,7 @@ struct scanner > int df_thickness; > int dropout_color[2]; > int buffermode; > + int batchmode; > int rollerdeskew; > int swdeskew; > int swdespeck; -- Sent with my mu4e -- sane-devel mailing list: sane-devel@lists.alioth.debian.org http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/sane-devel Unsubscribe: Send mail with subject "unsubscribe your_password" to sane-devel-requ...@lists.alioth.debian.org
Re: [sane-devel] Need Help getting Canon ImageClass MF244dw working
Dave Platt writes: >> Dave, >> >> Thank you very much, it did work, I used this. > > You're quite welcome! > >> I did notice that I do not have the same tweaks that Rolf and I had worked >> on on his ppa. I am guessing that his ppa gets updated more than the >> regular sane backend. > > He may be building from a custom tree, or one which is based on the > current top-of-branch development code at the SANE repository. Rolf's PPA builds from the nightly `git archive` tarball but does apply some Ubuntu inspired patches for better distro integration (as do *any* of the official packages of any Linux distribution). > There have been a number of changes committed to the repo since > 1.0.27 was released, I believe, and you would not have found any of > those in the 1.0.27 tarball you downloaded. > >> One last question. Is the folder that gets extracted for building >> (sane-backends-1.0.27) >> tied to anything, or can it be removed? > > You should be able to remove it. Once the files are installed in > /usr/local/ there won't be any back-links to the source or build > directories. If you want to do a `make uninstall` later, when the official packages have fixed the problem for example, you might want to keep it around though. Hope this helps, -- Olaf Meeuwissen, LPIC-2FSF Associate Member since 2004-01-27 GnuPG key: F84A2DD9/B3C0 2F47 EA19 64F4 9F13 F43E B8A4 A88A F84A 2DD9 Support Free Softwarehttps://my.fsf.org/donate Join the Free Software Foundation https://my.fsf.org/join -- sane-devel mailing list: sane-devel@lists.alioth.debian.org http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/sane-devel Unsubscribe: Send mail with subject "unsubscribe your_password" to sane-devel-requ...@lists.alioth.debian.org
Re: [sane-devel] Canon PIXMA MX925 - scan process now broken (does not end)
Hi Kay, Kay Drangmeister writes: > Hi, > > I am using the sane libs (Ubuntu 16.04) with a Canon Pixma MX925 > successfully for years now. Since some time (days, maybe weeks), the > scan process does not terminate well. There were two recent threads about similar issues that may be of interest https://lists.alioth.debian.org/pipermail/sane-devel/2017-July/035481.html https://lists.alioth.debian.org/pipermail/sane-devel/2017-July/035520.html Note, both threads continue on https://lists.alioth.debian.org/pipermail/sane-devel/2017-August/thread.html You could try reverting to 1.0.25+git20150528 @Rolf> I hope these recent problem don't have anything to do with my sanei threading changes. > [...] Hope this helps, -- Olaf Meeuwissen, LPIC-2FSF Associate Member since 2004-01-27 GnuPG key: F84A2DD9/B3C0 2F47 EA19 64F4 9F13 F43E B8A4 A88A F84A 2DD9 Support Free Softwarehttps://my.fsf.org/donate Join the Free Software Foundation https://my.fsf.org/join -- sane-devel mailing list: sane-devel@lists.alioth.debian.org http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/sane-devel Unsubscribe: Send mail with subject "unsubscribe your_password" to sane-devel-requ...@lists.alioth.debian.org
Re: [sane-devel] Restore support WorkCentre 3510 (may be 3520) in sane-backend-1.0.27
Hi Youry, Sorry for not following up on your related comment on GitLab.com[1] earlier. [1]: https://gitlab.com/sane-project/backends/commit/c9027378a12a6f67b22ee5fe203df1739486e3ad#note_37105915 Youry Metlitsky writes: > On WorkCentre 3515 dev->compressionTypes is 0x51 and (dev->compressionTypes & > (1 << 6)) is true. > On WorkCentre 3510 dev->compressionTypes is 0x41, but this device don't > support jpeg - this is error! Is the commit you commented on, which only conditionalizes compilation of the JPEG specific bits in the code, the cause of breakage or is the problem with the dev->compressionTypes checking? That is do things work when you build from the commit immediately before c9027378 or not? Hope this helps, -- Olaf Meeuwissen, LPIC-2FSF Associate Member since 2004-01-27 GnuPG key: F84A2DD9/B3C0 2F47 EA19 64F4 9F13 F43E B8A4 A88A F84A 2DD9 Support Free Softwarehttps://my.fsf.org/donate Join the Free Software Foundation https://my.fsf.org/join -- sane-devel mailing list: sane-devel@lists.alioth.debian.org http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/sane-devel Unsubscribe: Send mail with subject "unsubscribe your_password" to sane-devel-requ...@lists.alioth.debian.org
[sane-devel] Canon PIXMA MX925 - scan process now broken (does not end)
Hi, I am using the sane libs (Ubuntu 16.04) with a Canon Pixma MX925 successfully for years now. Since some time (days, maybe weeks), the scan process does not terminate well. After scanning, or after acquiring a preview in Gimp using xscanimage, the scan is read completely, but on the display of the device, the german message "Dokument wird gescannt" (document is being scanned) is remaining forever. When trying to scan a second image, or after acquiring the preview trying to scan the image for real, a timeout occurs. Unplugging and replugging the USB resolves the situation, display on scanner is emptied, scanadf (for example) can read the next image. It looks like a "scan completed - reset" is not being sent at the end of the scan process from the PC to the scanner. All of this has worked well before, I did not change my setup, except for applying all "ppa sane-git" updates of the libsane software. Due to holidays, I cannot tell exactly the version or date when it began to fail. Kind regards, Kay Drangmeister -- sane-devel mailing list: sane-devel@lists.alioth.debian.org http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/sane-devel Unsubscribe: Send mail with subject "unsubscribe your_password" to sane-devel-requ...@lists.alioth.debian.org
Re: [sane-devel] Maybe I am on the wrong list ...
On Sat, 01 Jul 2017 18:06:50 +0200 "Dr.-Ing. Dieter Jurzitza"wrote: > Dear listmembers, > maybe I am on the wrong list because my problem might be application - > specific, however. > I've sent several messages like this one before, and normally you send a meaningful subject and then apologize, that way people learn of what you're asking before dismissing it because you're too busy apologzing to tell people what you need. > I have set up a HP 7400C scanner, supported by the avision backend, it > is detected and working. So far, so good. > > Now, if I scan a black and white printed text with xsane and adjust all > parameters to default, 300dpi, Gray, contrast and brightness set to 0, > (=100%), the resutls are nice quality scans, black is black, background > is white. > > In contrast, attempting to do the very same with scanimage, calling: > > scanimage --mode Gray --contrast 0 --brightness 0 --resolution 300 > > outfile > > the resulting picture in "outfile" (same printed text as above) is very > bright, grey rather than black. Modifying brightness is making the > result worse, modifying contrast as well. I cannot achieve the same > result as with xsane - what makes me wonder as I had had expected to > work the same way > > Any ideas / hints for me? I could provide resulting scans for > explanation, however, I think I cannot upload anything. Use a post processing tool, like imagemgick, or gimp. You might also be interested in OCR. Sincerely, David -- sane-devel mailing list: sane-devel@lists.alioth.debian.org http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/sane-devel Unsubscribe: Send mail with subject "unsubscribe your_password" to sane-devel-requ...@lists.alioth.debian.org
Re: [sane-devel] [janitorial] leading whitespace: spaces XOR tabs
On Wed, 12 Jul 2017 15:35:36 +0200 Gerhard Jägerwrote: > > This whole exercise has made me look at the whole code base in a > > little more detail and, quite frankly, the use of leading whitespace > > is a total and utter mess. Some places are better of than others but > > on the whole it's pretty pathetic. > > > # Just make your editor visually distinguish spaces and tabs and > > > you'll > > # see. I used Emacs' whitespace-mode (in its default configuration) > > and # it "lit up the place" in a variety of colours. > > > So here's a few "rules" I'd like to apply in order to address > > > this. > > Each file > [...] > > # Personally, I would much prefer to uses spaces everywhere the file > > # format permits (with a minor execption for files used by make, see > > # above) over the board. > > # You may find the following blog post of interest ;-) > > # > > # > > https://stackoverflow.blog/2017/06/15/developers-use-spaces-make-money-use-tabs/ > > > > > If anyone objects, I'm open to suggestions, including "Why bother? > > > Just > > use spaces!" ;-) > > > If I hear nothing, the tools/style-check.sh script will be modified > > > to > > implement these rules and can then be use to check for any > > "violations" and (recursively) fix them. > > Are you sure you want to rework the whole code base? Is it a good idea? > Well maybe for unmaintained backends, but what about the others? In fact > I have here some long pending patch (64 bit awareness) that most > probably no longer apply. Isn't this a moot point? Use "diff -w" or it's git alternative (I don't know what it is). Sincerely, David -- sane-devel mailing list: sane-devel@lists.alioth.debian.org http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/sane-devel Unsubscribe: Send mail with subject "unsubscribe your_password" to sane-devel-requ...@lists.alioth.debian.org
[sane-devel] Olaf
Hi Olaf, This was sent to me only it looks like. Could you look into this please. Thank You, Curtis -- Forwarded message - From: Doug RobinsonHello, Please remove Doug off your email list as he has passed away. His widow -- sane-devel mailing list: sane-devel@lists.alioth.debian.org http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/sane-devel Unsubscribe: Send mail with subject "unsubscribe your_password" to sane-devel-requ...@lists.alioth.debian.org
Re: [sane-devel] Film scanning and infrared image cleaning
Hi Julian, * Julian Hauser[Aug 10. 2017 22:58]: > Hello everyone, > > I'm using the Reflecta 10T scanner using the pieusb backend. It mostly works > very well, thanks! One thing I have noticed though is that if I enable the > infrared scratch and dust removal option "Clean image" in Xsane, the detected > defects get painted over with a blurred dot. On film negatives, which have a > grainy structure, the results are clearly visible. I've uploaded an example > here: https://mis.julianhauser.com/index.php/s/MhSuFltcm0CLIMs. It would be > very nice if the corrections repaired the result taking into account the > structure of the neighbouring areas (as for example the "healing tool" in > GIMP does). > > Does the "overpainting" happen in the firmware of the scanner or is > that part of sane? it's part of sane, resp. the pieusb backend. See https://anonscm.debian.org/cgit/sane/sane-backends.git/tree/backend/pieusb_specific.c#n1321 where various sane_ir_* functions are called. > Two more things I've noticed with the scanner is that images always > come out reversed left-to-right All images (color, greyscale, b) ? In all resolutions ? > and greyscale scans make xsane crash. These things don't bother me much > as they are easily fixed with a script after scanning. I can send crash > logs if someone is interested in debugging this however. Please do ! ;-) Klaus -- SUSE Linux GmbH, GF: Felix Imendörffer, Jane Smithard, Graham Norton, HRB 21284 (AG Nürnberg) -- sane-devel mailing list: sane-devel@lists.alioth.debian.org http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/sane-devel Unsubscribe: Send mail with subject "unsubscribe your_password" to sane-devel-requ...@lists.alioth.debian.org