[sane-devel] Epson Perfection 1650

Sergey Smirnov svs@leaves.ru
Wed, 13 Feb 2002 13:34:58 +0300


I found that problem in  scanner.c kernel driver.
I increase NAK value for 1650 in scanner.h:
#define RD_NAK_TIMEOUT (160*HZ)
But scanner.c reset this value back to 40*HZ
...
switch (dev->descriptor.idVendor) { /* Scanner specific read timeout parameters */
         case 0x04b8:            /* Seiko/Epson */
                 scn->rd_nak_timeout = HZ * 40;
...
I have tested 1650 with rd_nak_timeout = HZ * 160.
I work fine with max resolution 3200.
Other way compile scanner as module and install it with read_timeout=160*100:
# insmod scanner read_timeout=16000

Willy Gardiol wrote:
> Hi!
> 
> this is exactly my problem!
> i think it is a bug in the scanner.o driver because i can perfectly scan 
> negatives at 1600 dpi under Windows2000 emulated under WMVare (so using huci 
> driver). My kernel is 2.4.17
> 
> 
> On Monday 11 February 2002 12:11, Sergey Smirnov wrote:
> 
>>I tried with both drivers:
>>uhci and usb-uhci.
>>I use USB Controller: Intel Corp. 82371AB PIIX4 USB (rev 01)
>>
>>Karl Heinz Kremer wrote:
>>
>>>One more question: What USB host controller are you using (OHCI or UHCI),
>>>and which driver? There are two for UHCI: uhci and usb-uhci. Somebody
>>>just reported performance issues with the uhci driver. If this is
>>>what you are using, you may want to try the other one.
>>>
>>>Karl Heinz
>>>
>>>On Thu, Feb 07, 2002 at 03:57:09PM +0300, Sergey Smirnov wrote:
>>>
>>>>Karl,
>>>>I'm using Debian unstable with kernel 2.4.18-pre8, sane 1.0.7(epson
>>>>backend 0.2.19, xsane 0.84
>>>>I have increased timeout up to 160
>>>>#define RD_NAK_TIMEOUT (160*HZ)
>>>>I also tried with SANE_DEBUG_EPSON=64
>>>>...
>>>>[epson] receive buf, expected = 4, got = 4
>>>>[epson] receive buf, expected = 45, got = 45
>>>>[epson] SANE_START: color: 19
>>>>[epson] SANE_START: resolution (x, y): (1600, 1600)
>>>>[epson] SANE_START: area[dots] (x-offset, y-offset), (x-range, y-range):
>>>>(765, 9900), (1488,
>>>>2273)
>>>>[epson] SANE_START: data format: 16
>>>>[epson] SANE_START: halftone: 0
>>>>[epson] SANE_START: brightness: 0
>>>>[epson] SANE_START: gamma: 2
>>>>[epson] SANE_START: zoom[percentage] (x, y): (100, 100)
>>>>[epson] SANE_START: color correction: 128
>>>>[epson] SANE_START: outline emphasis: 0
>>>>[epson] SANE_START: read mode: 0
>>>>[epson] SANE_START: mirror image: 0
>>>>[epson] SANE_START: (new B6 or B7 command ESC s): 0
>>>>[epson] SANE_START: (new B6 or B7 command ESC t): 128
>>>>[epson] SANE_START: line counter: 3
>>>>[epson] SANE_START: extension control: 1
>>>>[epson] SANE_START: (new B6 or B7 command ESC N): 1
>>>>[epson] send buf, size = 2
>>>>[epson] sane_get_parameters()
>>>>[epson] Preview = 0
>>>>[epson] Resolution = 1600
>>>>[epson] get para 0x80fbe80 0x80fc528 tlx 12.143967 tly 157.164154 brx
>>>>35.803833 bry 193.255493 [mm]
>>>>[epson] sane_read: begin
>>>>[epson] sane_read: begin scan1
>>>>[epson] error in receive - status = 5
>>>>[epson] receive buf, expected = 6, got = -1
>>>>...
>>>>Thank's.
>>>>
>>>>
>>>>>Sergey,
>>>>>
>>>>>which Linux distribution are you using? What kernel and
>>>>>Sane version?
>>>>>
>>>>>You probably have some messages on your console about
>>>>>USB timeouts after this happens. The reason is very likely
>>>>>that your kernel is too old and does not have the increased
>>>>>timeout for USB scanner transmissions.
>>>>>
>>>>>Please see my page at http://www.khk.net/sane/faq.html for
>>>>>more information.
>>>>>
>>>>>Karl Heinz
>>>>>
>>>>>Sergey Smirnov <svs@leaves.ru> said:
>>>>>
>>>>>>Hi,
>>>>>>I have problem with Epson Perfection 1650.
>>>>>>I can't scan negative film with resolution more than 1200.
>>>>>>I/o error and only power off reset scanner.
>>>>>>--
>>>>>>Sergey Smirnov
>>>>>>_______________________________________________
>>>>>>Sane-devel mailing list
>>>>>>Sane-devel@www.mostang.com
>>>>>>http://www.mostang.com/mailman/listinfo/sane-devel
>>>>>>
>>>>--
>>>>Sergey Smirnov
>>>>
> _______________________________________________
> Sane-devel mailing list
> Sane-devel@www.mostang.com
> http://www.mostang.com/mailman/listinfo/sane-devel
> 
-- 
Sergey Smirnov