[sane-devel] Epson SX600FW support

Chris Bagwell chris at cnpbagwell.com
Thu Jan 15 01:33:54 UTC 2009


On 1/14/2009 12:00 PM, Thibaut GIRKA wrote:
> Hi,
> I bought an Epson SX600FW scanner/printer, and it doesn't work with SANE
> (at least the version in debian/testing).
> When I do "scanimage -L", here is what I get:
> "[epson2] Cannot send this command to a networked scanner"
>    
I have recently purchased an Epson Artisan 800 which based on external 
appearance are probably related.  I also get this same error message.

To be more specific though, we are using this with the ethernet/wifi 
connection and not USB.  Also, its worth pointing out the epson2 driver 
does auto-discover the scanner and perform basic communications with it 
(as you mention towards the end).
> So, why cannot this command be sent to a networked scanner?
>    
The reason for the failure in code seems reasonable.  The code is using 
a function that defines no length for the response message.  It would be 
painful to implement waiting for random length packets responses coming 
back from the printer.  So the better question to me is why was a length 
not specified?  Do all scanners have the same length for this command?
> However, I modified epson2.c (at line 1068) to disable the identity2
> request.
> By doing that, I can scan.
A similar solution is to modify the code to specify a length of the 
response to expect.  I've not put much effort in this debug yet because 
I requested access to developer docs from Epsons developer web page and 
was hoping to hear back... No word in 2 weeks though so they may have 
thought I'm not important enough to get it.

But google turned up a PDF of some other random Epson scanner that shows 
the length of identity2 response.  The patch at the end of this email 
specifies the response length and also fixes the issue.  As I've spent a 
grand total of 1 hour on researching this so far, I do not know enough 
yet to decide if the length is the real fix (and safe for all scanners) 
or disabling the call like you did is right (esci_request_identity() 
also uses a zero length but is wrapped by a != SANE_EPSON_NET to prevent 
similar error).

Hopefully, others on the list already have experience and can 
immediately answer.

> However, I get an error when requesting a
> preview, and the connexion between the scanner and the computer stops
> from time to time (I then have to restart the scanner).
>    
Same behavior for me.  Simple "scanimage" appeared to scan a blank page 
when I tried but xsane's preview window errored out.  I'm hoping this 
next part is as easy to debug but I've been side track cleaning up some 
sane build stuff at the moment.

Also, heres to hoping Epson has some Docs they can distribute to help my 
understanding occur faster. :-)

Chris

Index: epson2-commands.c
===================================================================
RCS file: /cvsroot/sane/sane-backends/backend/epson2-commands.c,v
retrieving revision 1.4
diff -u -w -r1.4 epson2-commands.c
--- epson2-commands.c   3 Feb 2008 12:09:09 -0000       1.4
+++ epson2-commands.c   15 Jan 2009 01:09:27 -0000
@@ -702,7 +702,7 @@
         params[0] = ESC;
         params[1] = s->hw->cmd->request_identity2;

-       status = e2_cmd_info_block(s, params, 2, 0, buf, &len);
+        status = e2_cmd_info_block(s, params, 2, 46, buf, &len);
         if (status != SANE_STATUS_GOOD)
                 return status;




More information about the sane-devel mailing list