kopia lustrzana https://gitlab.com/sane-project/website
285 wiersze
10 KiB
HTML
285 wiersze
10 KiB
HTML
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"
|
|
"http://www.w3.org/TR/REC-html40/loose.dtd">
|
|
<HTML>
|
|
<HEAD>
|
|
<TITLE>sane-devel: Re: canon backend driver fix</TITLE>
|
|
<META NAME="Author" CONTENT="Mitsuru Okaniwa (m-okaniwa@bea.hi-ho.ne.jp)">
|
|
<META NAME="Subject" CONTENT="Re: canon backend driver fix">
|
|
</HEAD>
|
|
<BODY BGCOLOR="#FFFFFF" TEXT="#000000">
|
|
<H1>Re: canon backend driver fix</H1>
|
|
<!-- received="Thu Jan 25 20:00:29 2001" -->
|
|
<!-- isoreceived="20010126040029" -->
|
|
<!-- sent="Fri, 26 Jan 2001 12:50:22 +0900" -->
|
|
<!-- isosent="20010126035022" -->
|
|
<!-- name="Mitsuru Okaniwa" -->
|
|
<!-- email="m-okaniwa@bea.hi-ho.ne.jp" -->
|
|
<!-- subject="Re: canon backend driver fix" -->
|
|
<!-- id="002701c0874c$7f9661c0$6425530a@necpcuser" -->
|
|
<!-- inreplyto="3A6B4D21.5B84A255@cubic.org" -->
|
|
<STRONG>From:</STRONG> Mitsuru Okaniwa (<A HREF="mailto:m-okaniwa@bea.hi-ho.ne.jp?Subject=Re:%20canon%20backend%20driver%20fix&In-Reply-To=<002701c0874c$7f9661c0$6425530a@necpcuser>"><EM>m-okaniwa@bea.hi-ho.ne.jp</EM></A>)<BR>
|
|
<STRONG>Date:</STRONG> Thu Jan 25 2001 - 19:50:22 PST
|
|
<P>
|
|
<!-- next="start" -->
|
|
<LI><STRONG>Next message:</STRONG> <A HREF="0287.html">Shea Martin: "sane 1.0.1/ how to disabe gimp compat"</A>
|
|
<UL>
|
|
<LI><STRONG>Previous message:</STRONG> <A HREF="0285.html">Nils Gundelach: "Re: Scanmaker 636"</A>
|
|
<LI><STRONG>In reply to:</STRONG> <A HREF="0233.html">doj: "canon backend driver fix"</A>
|
|
<!-- nextthread="start" -->
|
|
<LI><STRONG>Next in thread:</STRONG> <A HREF="0288.html">doj: "Re: canon backend driver fix"</A>
|
|
<LI><STRONG>Next in thread:</STRONG> <A HREF="0238.html">Randolph Bentson: "Re: ADF scanner question"</A>
|
|
<LI><STRONG>Reply:</STRONG> <A HREF="0288.html">doj: "Re: canon backend driver fix"</A>
|
|
<!-- reply="end" -->
|
|
<LI><STRONG>Messages sorted by:</STRONG>
|
|
<A HREF="date.html#286">[ date ]</A>
|
|
<A HREF="index.html#286">[ thread ]</A>
|
|
<A HREF="subject.html#286">[ subject ]</A>
|
|
<A HREF="author.html#286">[ author ]</A>
|
|
</UL>
|
|
<HR NOSHADE><P>
|
|
<!-- body="start" -->
|
|
<P>
|
|
Dear Mr.Doj
|
|
<BR>
|
|
<P>I'm the CanoScan user.
|
|
<BR>
|
|
I have a CanoScan FB620S, and I'm using the model in SANE1.0.3 on Linux.
|
|
<BR>
|
|
About your patch, would you teach me ?
|
|
<BR>
|
|
<P>----- Original Message -----
|
|
<BR>
|
|
from: "doj" <<A HREF="mailto:doj@cubic.org?Subject=Re:%20canon%20backend%20driver%20fix&In-Reply-To=<002701c0874c$7f9661c0$6425530a@necpcuser>">doj@cubic.org</A>>
|
|
<BR>
|
|
to : <<A HREF="mailto:sane-devel@mostang.com?Subject=Re:%20canon%20backend%20driver%20fix&In-Reply-To=<002701c0874c$7f9661c0$6425530a@necpcuser>">sane-devel@mostang.com</A>>
|
|
<BR>
|
|
sent : 22 Jan. 2001 at 5:57
|
|
<BR>
|
|
subject: canon backend driver fix
|
|
<BR>
|
|
<P><P><EM>> I am using an CanoScan 300. The 0.99 versions of SANE were working with
|
|
</EM><BR>
|
|
<EM>> my scanner, but since v1.0 the driver complained.
|
|
</EM><BR>
|
|
Are you using SANE 1.0.1 now ?
|
|
<BR>
|
|
Or SANE 1.0.3 ?
|
|
<BR>
|
|
<P><EM>> Now I have worked
|
|
</EM><BR>
|
|
<EM>> myself through the sources and found some glitches, which I think result
|
|
</EM><BR>
|
|
<EM>> from another bug beeing solved not 100% correct.
|
|
</EM><BR>
|
|
What glitches did you have with a CanoScan 300 ?
|
|
<BR>
|
|
<P><EM>> With the patch I have attached everything is working fine with my system
|
|
</EM><BR>
|
|
<EM>> again. I think the patch should work with others as well.
|
|
</EM><BR>
|
|
I'm a beginner of SANE or Linux.
|
|
<BR>
|
|
And I have the problem the warning error at "make all" of Canon Backend(v
|
|
<BR>
|
|
991114) with SANE 1.0.3.
|
|
<BR>
|
|
It is a "warning: comparison between signed and unsigned".
|
|
<BR>
|
|
So, I think there is a hint with my problem in your patch.
|
|
<BR>
|
|
But I don't understand the parts of your modification well.
|
|
<BR>
|
|
Would you teach me the meaning of the following parts in your modification
|
|
<BR>
|
|
if you are OK ?
|
|
<BR>
|
|
<P><P>----------------------------------------------------------------------------
|
|
<BR>
|
|
<PRE>
|
|
----
|
|
<P><P>> diff -w -b -B -u -U 5 -r -P sane-backends-1.0.4/backend/canon-sane.c
|
|
sane-backends-1.0.4.doj/backend/canon-sane.c
|
|
> --- sane-backends-1.0.4/backend/canon-sane.c Sat Aug 12 17:09:02 2000
|
|
> +++ sane-backends-1.0.4.doj/backend/canon-sane.c Sun Dec 31 00:36:39 2000
|
|
> @@ -103,22 +103,22 @@
|
|
> for (dev = first_dev; dev; dev = dev->next)
|
|
> {
|
|
> if (strcmp (dev->sane.name, devnam) == 0)
|
|
> break;
|
|
> }
|
|
> + }
|
|
> + else
|
|
> + {
|
|
> + dev = first_dev;
|
|
> + }
|
|
>
|
|
> if (!dev)
|
|
> {
|
|
> status = attach (devnam, &dev);
|
|
> if (status != SANE_STATUS_GOOD)
|
|
> return (status);
|
|
> }
|
|
> - }
|
|
> - else
|
|
> - {
|
|
> - dev = first_dev;
|
|
> - }
|
|
>
|
|
> if (!dev)
|
|
> return (SANE_STATUS_INVAL);
|
|
>
|
|
> s = malloc (sizeof (*s));
|
|
> @@ -1065,11 +1065,11 @@
|
|
> /* { */
|
|
> /* DBG (1, "attach: GET SCAN MODE for scan control conditions
|
|
failed\n"); */
|
|
> /* sanei_scsi_close (s->fd); */
|
|
> /* return (SANE_STATUS_INVAL); */
|
|
> /* } */
|
|
> - for (i=0; i<buf_size; i++)
|
|
> + for (i=0; i<(int)buf_size; i++)
|
|
> {
|
|
> DBG(3, "scan mode control byte[%d] = %d\n", i, ebuf[i]);
|
|
> }
|
|
>
|
|
> DBG (3, "attach: sending GET SCAN MODE for transparency unit\n");
|
|
> @@ -1081,11 +1081,11 @@
|
|
> {
|
|
> DBG (1, "attach: GET SCAN MODE for transparency unit failed\n");
|
|
> sanei_scsi_close (s->fd);
|
|
> return (SANE_STATUS_INVAL);
|
|
> }
|
|
> - for (i=0; i<buf_size; i++)
|
|
> + for (i=0; i<(int)buf_size; i++)
|
|
> {
|
|
> DBG(3, "scan mode control byte[%d] = %d\n", i, ebuf[i]);
|
|
> }
|
|
>
|
|
> #endif
|
|
> @@ -1291,11 +1291,11 @@
|
|
> {
|
|
> DBG (1, "sane_start: GET SCAN MODE for scan control conditions
|
|
failed\n");
|
|
> sanei_scsi_close (s->fd);
|
|
> return (SANE_STATUS_INVAL);
|
|
> }
|
|
> - for (i=0; i<buf_size; i++)
|
|
> + for (i=0; i<(int)buf_size; i++)
|
|
> {
|
|
> DBG(3, "scan mode byte[%d] = %d\n", i, ebuf[i]);
|
|
> }
|
|
> #endif
|
|
>
|
|
> diff -w -b -B -u -U 5 -r -P sane-backends-1.0.4/backend/canon-scsi.c
|
|
sane-backends-1.0.4.doj/backend/canon-scsi.c
|
|
> --- sane-backends-1.0.4/backend/canon-scsi.c Sat Aug 12 17:09:02 2000
|
|
> +++ sane-backends-1.0.4.doj/backend/canon-scsi.c Sun Dec 31 00:29:26 2000
|
|
> @@ -377,11 +377,11 @@
|
|
> (page == SCAN_CONTROL_CONDITIONS) ? 0x14 : 0x24;
|
|
>
|
|
> memcpy (cmd + 10, data, (page == TRANSPARENCY_UNIT) ? 8 :
|
|
> (page == SCAN_CONTROL_CONDITIONS) ? 16 : 24);
|
|
>
|
|
> - for(i = 0; i < sizeof(cmd); i++)
|
|
> + for(i = 0; i <(int) sizeof(cmd); i++)
|
|
> {
|
|
> DBG (31, "define scan mode: cmd[%d]='0x%0X'\n", i, cmd[i]);
|
|
> }
|
|
> cmdlen = (page == TRANSPARENCY_UNIT) ? 18 :
|
|
> (page == SCAN_CONTROL_CONDITIONS) ? 26 : 34;
|
|
> diff -w -b -B -u -U 5 -r -P sane-backends-1.0.4/backend/canon.c
|
|
sane-backends-1.0.4.doj/backend/canon.c
|
|
> --- sane-backends-1.0.4/backend/canon.c Sat Aug 12 17:09:03 2000
|
|
> +++ sane-backends-1.0.4.doj/backend/canon.c Sun Dec 31 00:27:48 2000
|
|
> @@ -226,11 +226,11 @@
|
|
> {
|
|
> DBG (1, "get scan mode failed: %s\n", sane_strstatus (status));
|
|
> return;
|
|
> }
|
|
>
|
|
> - for (i=0; i<buf_size; i++)
|
|
> + for (i=0; i<(int)buf_size; i++)
|
|
> {
|
|
> DBG(3, "scan mode control byte[%d] = %d\n", i, tbuf[i]);
|
|
> }
|
|
> dev->tpu.Status = ( tbuf[2 + 4 + 5] >> 7 ) ?
|
|
> TPU_STAT_INACTIVE : TPU_STAT_NONE;
|
|
> @@ -280,11 +280,11 @@
|
|
> DBG (1, "get scan mode failed: %s\n", sane_strstatus (status));
|
|
> perror("get scan mode failed");
|
|
> return;
|
|
> }
|
|
>
|
|
> - for (i=0; i<buf_size; i++)
|
|
> + for (i=0; i<(int)buf_size; i++)
|
|
> {
|
|
> DBG(3, "scan mode control byte[%d] = %d\n", i, abuf[i]);
|
|
> /* printf("scan mode control byte[%d] = %d\n", i, abuf[i]); */
|
|
> }
|
|
>
|
|
> @@ -594,11 +594,11 @@
|
|
> {
|
|
> DBG (1, "attach: GET SCAN MODE for scan control conditions
|
|
failed\n");
|
|
> sanei_scsi_close (fd);
|
|
> return (SANE_STATUS_INVAL);
|
|
> }
|
|
> - for (i=0; i<buf_size; i++)
|
|
> + for (i=0; i<(int)buf_size; i++)
|
|
> {
|
|
> DBG(3, "scan mode byte[%d] = %d\n", i, ebuf[i]);
|
|
> }
|
|
>
|
|
> DBG (3, "attach: sending (extended) INQUIRY\n");
|
|
> @@ -1123,11 +1123,11 @@
|
|
>
|
|
> /* Build the histograms */
|
|
> DBG(7, "sizeof(histo)='%lu'\n", (unsigned long) sizeof(histo));
|
|
> memset (histo, 0, sizeof(histo));
|
|
>
|
|
> - for(i=0; i<bread; i+=3)
|
|
> + for(i=0; i<(int)bread; i+=3)
|
|
> {
|
|
> /* j = (int)adjbuf[i] - 71; */
|
|
> /* j = (j<0) ? -j : j; */
|
|
> /* ++histo[RED][j]; */
|
|
> ++histo[RED][(int)adjbuf[i]];
|
|
> Binary files sane-backends-1.0.4/core and sane-backends-1.0.4.doj/core
|
|
differ
|
|
>
|
|
<P>regards,
|
|
<P>Mitsuru Okaniwa
|
|
<P><P>--
|
|
Source code, list archive, and docs: <A HREF="http://www.mostang.com/sane/">http://www.mostang.com/sane/</A>
|
|
To unsubscribe: echo unsubscribe sane-devel | mail <A HREF="mailto:majordomo@mostang.com?Subject=Re:%20canon%20backend%20driver%20fix&In-Reply-To=<002701c0874c$7f9661c0$6425530a@necpcuser>">majordomo@mostang.com</A>
|
|
</PRE>
|
|
<P><!-- body="end" -->
|
|
<HR NOSHADE>
|
|
<UL>
|
|
<!-- next="start" -->
|
|
<LI><STRONG>Next message:</STRONG> <A HREF="0287.html">Shea Martin: "sane 1.0.1/ how to disabe gimp compat"</A>
|
|
<LI><STRONG>Previous message:</STRONG> <A HREF="0285.html">Nils Gundelach: "Re: Scanmaker 636"</A>
|
|
<LI><STRONG>In reply to:</STRONG> <A HREF="0233.html">doj: "canon backend driver fix"</A>
|
|
<!-- nextthread="start" -->
|
|
<LI><STRONG>Next in thread:</STRONG> <A HREF="0288.html">doj: "Re: canon backend driver fix"</A>
|
|
<LI><STRONG>Next in thread:</STRONG> <A HREF="0238.html">Randolph Bentson: "Re: ADF scanner question"</A>
|
|
<LI><STRONG>Reply:</STRONG> <A HREF="0288.html">doj: "Re: canon backend driver fix"</A>
|
|
<!-- reply="end" -->
|
|
<LI><STRONG>Messages sorted by:</STRONG>
|
|
<A HREF="date.html#286">[ date ]</A>
|
|
<A HREF="index.html#286">[ thread ]</A>
|
|
<A HREF="subject.html#286">[ subject ]</A>
|
|
<A HREF="author.html#286">[ author ]</A>
|
|
</UL>
|
|
<!-- trailer="footer" -->
|
|
<HR NOSHADE>
|
|
<P>
|
|
<SMALL>
|
|
<EM>
|
|
This archive was generated by <A HREF="http://www.hypermail.org/">hypermail 2b29</A>
|
|
: <EM>Thu Jan 25 2001 - 20:41:24 PST</EM>
|
|
</EM>
|
|
</SMALL>
|
|
</BODY>
|
|
</HTML>
|