I'm trying to get a Seiko Epson Corp. Perfection 4490 Photo scanner working with on my Gentoo AMD64 box with SANE 1.0.20/backend `epson' is version 1.0.247. However all I can get out of it is "scanimage: sane_start: Invalid argument" Seems to come from this setting, but I don't know where this is coming from:
[epson] sane_start: Setting data format to 1 bits Any insights to getting this to work? Below is debugging output from the SANE/Epson backend and my Gentoo system info report. scanimage --version scanimage (sane-backends) 1.0.20; backend version 1.0.20 $ lsusb Bus 001 Device 003: ID 04b8:0119 Seiko Epson Corp. Perfection 4490 Photo $ scanimage -L device `epson:libusb:001:003' is a Epson flatbed scanner $ scanimage -T scanimage: rounded value of br-x from -32768 to 0 scanimage: rounded value of br-y from -32768 to 0 scanimage: sane_start: Invalid argument $ scanimage -d epson -T scanimage: rounded value of br-x from -32768 to 0 scanimage: rounded value of br-y from -32768 to 0 scanimage: sane_start: Invalid argument $ export SANE_DEBUG_EPSON=128 $ export SANE_DEBUG_DLL=128 $ export SANE_DEBUG_SANEI_USB=128 $ scanimage -d epson -T {Summary Start:} [sanei_usb] sanei_usb_read_bulk: wanted 4 bytes, got 1 bytes [epson] w_cmd_count = 2 [epson] r_cmd_count = 2 [epson] receive buf, expected = 4, got = 1 [epson] buf[0] 15 . [epson] code 15 [epson] type 0x00 [epson] level 0x00 [epson] no option equipment installed [epson] Unknown type or level , using B3 [epson] sane_start: Setting data format to 1 bits scanimage: sane_start: Invalid argument {Summary End} {Full Spew:} [sanei_debug] Setting debug level of dll to 128. [dll] sane_init: SANE dll backend version 1.0.12 from sane-backends 1.0.20 [dll] sane_init/read_dlld: processing /etc/sane.d/dll.d ... [dll] sane_init/read_dlld: done. [dll] sane_init/read_config: reading dll.conf [dll] add_backend: adding backend `net' {Skipp the loading of most other devices here as not relevant} [dll] add_backend: adding backend `epson' [dll] add_backend: adding backend `epson2' [dll] add_backend: adding backend `snapscan' [dll] add_backend: adding backend `v4l' [dll] add_backend: adding backend `hpaio' [dll] sane_open: trying to open `epson' [dll] load: searching backend `epson' in `/usr/lib64/sane' [dll] load: trying to load `/usr/lib64/sane/libsane-epson.so.1' [dll] load: dlopen()ing `/usr/lib64/sane/libsane-epson.so.1' [dll] init: initializing backend `epson' [sanei_debug] Setting debug level of epson to 128. [epson] sane_init: sane-backends 1.0.20 [sanei_debug] Setting debug level of sanei_usb to 128. [sanei_usb] sanei_usb_init: marking existing devices [sanei_usb] sanei_usb_init: Looking for kernel scanner devices [sanei_usb] sanei_usb_init: Looking for libusb devices usb_set_debug: Setting debugging level to 255 (on) usb_os_find_busses: Found 001 usb_os_find_busses: Found 002 usb_os_find_devices: Found 003 on 001 usb_os_find_devices: Found 002 on 001 usb_os_find_devices: Found 001 on 001 error obtaining child information: Inappropriate ioctl for device error obtaining child information: Inappropriate ioctl for device usb_os_find_devices: Found 001 on 002 [sanei_usb] sanei_usb_init: found libusb device (0x04b8/0x0119) interface 0 at libusb:001:003 [sanei_usb] store_device: add dn 0 with libusb:001:003 [sanei_usb] sanei_usb_init: device 0x0d49/0x7310, interface 0 doesn't look like a scanner (0/8) [sanei_usb] sanei_usb_init: device 0x0d49/0x7310: no suitable interfaces [sanei_usb] sanei_usb_init: device 0x1d6b/0x0002, interface 0 doesn't look like a scanner (9/9) [sanei_usb] sanei_usb_init: device 0x1d6b/0x0002: no suitable interfaces [sanei_usb] sanei_usb_init: device 0x1d6b/0x0001, interface 0 doesn't look like a scanner (9/9) [sanei_usb] sanei_usb_init: device 0x1d6b/0x0001: no suitable interfaces [sanei_usb] sanei_usb_init: found 1 devices [sanei_usb] sanei_usb_init: device 00 is libusb:001:003 [epson] sane_init, ># epson.conf< [epson] sane_init, >#< [epson] sane_init, ># here are some examples for how to configure the EPSON backend< [epson] sane_init, >#< [epson] sane_init, ># SCSI scanner:< [epson] sane_init, >#scsi EPSON< [epson] sane_init, ># for the GT-6500:< [epson] sane_init, >#scsi "EPSON SC"< [epson] sane_init, >#< [epson] sane_init, ># Parallel port scanner:< [epson] sane_init, >#pio 0x278< [epson] sane_init, >#pio 0x378< [epson] sane_init, >#pio 0x3BC< [epson] sane_init, >#< [epson] sane_init, ># USB scanner:< [epson] sane_init, ># There are two different methods of configuring a USB scanner: libusb and the kernel module< [epson] sane_init, ># For any system with libusb support (which is pretty much any recent Linux distribution) the< [epson] sane_init, ># following line is sufficient. This however assumes that the connected scanner (or to be more< [epson] sane_init, ># accurate, it's device ID) is known to the backend.< [epson] sane_init, >#usb< [epson] sane_init, ># For libusb support for unknown scanners use the following command< [epson] sane_init, ># usb <product ID> <device ID>< [epson] sane_init, ># e.g.:< [epson] sane_init, >usb 0x4b8 0x119< [sanei_usb] sanei_usb_find_devices: vendor=0x04b8, product=0x0119 [epson] attach_one_usb(libusb:001:003) [epson] SANE Epson Backend v0.2.47 - 2006-08-21 [epson] attach(libusb:001:003, 3) [epson] attach: opening libusb:001:003 [sanei_usb] sanei_usb_open: trying to open device `libusb:001:003' [sanei_usb] sanei_usb_open: configuration nr: 0 [sanei_usb] sanei_usb_open: interface nr: 0 [sanei_usb] sanei_usb_open: alt_setting nr: 0 [sanei_usb] sanei_usb_open: endpoint nr: 0 [sanei_usb] sanei_usb_open: direction: 128 [sanei_usb] sanei_usb_open: address: 1 transfertype: 2 [sanei_usb] sanei_usb_open: found bulk-in endpoint (address 0x01) [sanei_usb] sanei_usb_open: endpoint nr: 1 [sanei_usb] sanei_usb_open: direction: 0 [sanei_usb] sanei_usb_open: address: 2 transfertype: 2 [sanei_usb] sanei_usb_open: found bulk-out endpoint (address 0x02) [sanei_usb] sanei_usb_open: opened usb device `libusb:001:003' (*dn=0) [sanei_usb] sanei_usb_get_vendor_product: device 0: vendorID: 0x04b8, productID: 0x0119 [epson] Found valid EPSON scanner: 0x4b8/0x119 (vendorID/productID) [epson] reset() [epson] send buf, size = 2 [epson] buf[0] 1b . [epson] buf[1] 40 @ [sanei_usb] sanei_usb_write_bulk: trying to write 2 bytes [sanei_usb] 000 1B 40 .@ [sanei_usb] sanei_usb_write_bulk: wanted 2 bytes, wrote 2 bytes [epson] w_cmd_count = 1 [epson] r_cmd_count = 0 [sanei_usb] sanei_usb_read_bulk: trying to read 1 bytes [sanei_usb] 000 15 . [sanei_usb] sanei_usb_read_bulk: wanted 1 bytes, got 1 bytes [epson] w_cmd_count = 1 [epson] r_cmd_count = 1 [epson] receive buf, expected = 1, got = 1 [epson] buf[0] 15 . [epson] get_identity_information() [epson] send buf, size = 2 [epson] buf[0] 1b . [epson] buf[1] 49 I [sanei_usb] sanei_usb_write_bulk: trying to write 2 bytes [sanei_usb] 000 1B 49 .I [sanei_usb] sanei_usb_write_bulk: wanted 2 bytes, wrote 2 bytes [epson] w_cmd_count = 2 [epson] r_cmd_count = 1 [sanei_usb] sanei_usb_read_bulk: trying to read 4 bytes [sanei_usb] 000 15 . [sanei_usb] sanei_usb_read_bulk: wanted 4 bytes, got 1 bytes [epson] w_cmd_count = 2 [epson] r_cmd_count = 2 [epson] receive buf, expected = 4, got = 1 [epson] buf[0] 15 . [epson] code 15 [epson] type 0x00 [epson] level 0x00 [epson] no option equipment installed [epson] Unknown type or level , using B3 [epson] fbf tlx 0.000000 tly 0.000000 brx -32768.000000 bry -32768.000000 [mm] [epson] send buf, size = 2 [epson] buf[0] 1b . [epson] buf[1] 44 D [sanei_usb] sanei_usb_write_bulk: trying to write 2 bytes [sanei_usb] 000 1B 44 .D [sanei_usb] sanei_usb_write_bulk: wanted 2 bytes, wrote 2 bytes [epson] w_cmd_count = 3 [epson] r_cmd_count = 2 [sanei_usb] sanei_usb_read_bulk: trying to read 1 bytes [sanei_usb] 000 15 . [sanei_usb] sanei_usb_read_bulk: wanted 1 bytes, got 1 bytes [epson] w_cmd_count = 3 [epson] r_cmd_count = 3 [epson] receive buf, expected = 1, got = 1 [epson] buf[0] 15 . [epson] send buf, size = 2 [epson] buf[0] 1b . [epson] buf[1] 44 D [sanei_usb] sanei_usb_write_bulk: trying to write 2 bytes [sanei_usb] 000 1B 44 .D [sanei_usb] sanei_usb_write_bulk: wanted 2 bytes, wrote 2 bytes [epson] w_cmd_count = 4 [epson] r_cmd_count = 3 [sanei_usb] sanei_usb_read_bulk: trying to read 1 bytes [sanei_usb] 000 15 . [sanei_usb] sanei_usb_read_bulk: wanted 1 bytes, got 1 bytes [epson] w_cmd_count = 4 [epson] r_cmd_count = 4 [epson] receive buf, expected = 1, got = 1 [epson] buf[0] 15 . [epson] send buf, size = 2 [epson] buf[0] 1b . [epson] buf[1] 44 D [sanei_usb] sanei_usb_write_bulk: trying to write 2 bytes [sanei_usb] 000 1B 44 .D [sanei_usb] sanei_usb_write_bulk: wanted 2 bytes, wrote 2 bytes [epson] w_cmd_count = 5 [epson] r_cmd_count = 4 [sanei_usb] sanei_usb_read_bulk: trying to read 1 bytes [sanei_usb] 000 15 . [sanei_usb] sanei_usb_read_bulk: wanted 1 bytes, got 1 bytes [epson] w_cmd_count = 5 [epson] r_cmd_count = 5 [epson] receive buf, expected = 1, got = 1 [epson] buf[0] 15 . [epson] Max. supported color depth = 8 [epson] request_focus_position() [epson] Disabling 'Set Focus' support [epson] send buf, size = 2 [epson] buf[0] 1b . [epson] buf[1] 66 f [sanei_usb] sanei_usb_write_bulk: trying to write 2 bytes [sanei_usb] 000 1B 66 .f [sanei_usb] sanei_usb_write_bulk: wanted 2 bytes, wrote 2 bytes [epson] w_cmd_count = 6 [epson] r_cmd_count = 5 [sanei_usb] sanei_usb_read_bulk: trying to read 4 bytes [sanei_usb] 000 15 . [sanei_usb] sanei_usb_read_bulk: wanted 4 bytes, got 1 bytes [epson] w_cmd_count = 6 [epson] r_cmd_count = 6 [epson] receive buf, expected = 4, got = 1 [epson] buf[0] 15 . [epson] code 15 [epson] scanner model: [epson] close_scanner(fd = 0) [epson] w_cmd_count = 6 [epson] r_cmd_count = 6 [epson] w_cmd_count = 6 [epson] r_cmd_count = 6 [sanei_usb] sanei_usb_close: closing device 0 [epson] sane_init, ># And for the scanner module, use the following configuration:< [epson] sane_init, >#usb /dev/usbscanner0< [epson] sane_init, >#usb /dev/usb/scanner0< [dll] init: backend `epson' is version 1.0.247 [epson] sane_open() [epson] init_options() [epson] open_scanner() [sanei_usb] sanei_usb_open: trying to open device `libusb:001:003' [sanei_usb] sanei_usb_open: configuration nr: 0 [sanei_usb] sanei_usb_open: interface nr: 0 [sanei_usb] sanei_usb_open: alt_setting nr: 0 [sanei_usb] sanei_usb_open: endpoint nr: 0 [sanei_usb] sanei_usb_open: direction: 128 [sanei_usb] sanei_usb_open: address: 1 transfertype: 2 [sanei_usb] sanei_usb_open: found bulk-in endpoint (address 0x01) [sanei_usb] sanei_usb_open: we already have a bulk-in endpoint (address: 0x81), ignoring the new one [sanei_usb] sanei_usb_open: endpoint nr: 1 [sanei_usb] sanei_usb_open: direction: 0 [sanei_usb] sanei_usb_open: address: 2 transfertype: 2 [sanei_usb] sanei_usb_open: found bulk-out endpoint (address 0x02) [sanei_usb] sanei_usb_open: we already have a bulk-out endpoint (address: 0x02), ignoring the new one [sanei_usb] sanei_usb_open: opened usb device `libusb:001:003' (*dn=0) [dll] sane_open: open successful [dll] sane_get_option_descriptor(handle=0xa25610,option=0) [dll] sane_control_option(handle=0xa25610,option=0,action=0,value=0x7fffe9d81958,info=(nil)) [dll] sane_get_option_descriptor(handle=0xa25610,option=0) [dll] sane_control_option(handle=0xa25610,option=0,action=0,value=0x7fffe9d7f844,info=(nil)) [dll] sane_get_option_descriptor(handle=0xa25610,option=1) [dll] sane_get_option_descriptor(handle=0xa25610,option=2) [dll] sane_get_option_descriptor(handle=0xa25610,option=3) [dll] sane_get_option_descriptor(handle=0xa25610,option=4) [dll] sane_get_option_descriptor(handle=0xa25610,option=5) [dll] sane_get_option_descriptor(handle=0xa25610,option=6) [dll] sane_get_option_descriptor(handle=0xa25610,option=7) [dll] sane_get_option_descriptor(handle=0xa25610,option=8) [dll] sane_get_option_descriptor(handle=0xa25610,option=9) [dll] sane_get_option_descriptor(handle=0xa25610,option=10) [dll] sane_get_option_descriptor(handle=0xa25610,option=11) [dll] sane_get_option_descriptor(handle=0xa25610,option=12) [dll] sane_get_option_descriptor(handle=0xa25610,option=13) [dll] sane_get_option_descriptor(handle=0xa25610,option=14) [dll] sane_get_option_descriptor(handle=0xa25610,option=15) [dll] sane_get_option_descriptor(handle=0xa25610,option=16) [dll] sane_get_option_descriptor(handle=0xa25610,option=17) [dll] sane_get_option_descriptor(handle=0xa25610,option=18) [dll] sane_get_option_descriptor(handle=0xa25610,option=19) [dll] sane_get_option_descriptor(handle=0xa25610,option=20) [dll] sane_get_option_descriptor(handle=0xa25610,option=21) [dll] sane_get_option_descriptor(handle=0xa25610,option=22) [dll] sane_get_option_descriptor(handle=0xa25610,option=23) [dll] sane_get_option_descriptor(handle=0xa25610,option=24) [dll] sane_get_option_descriptor(handle=0xa25610,option=25) [dll] sane_get_option_descriptor(handle=0xa25610,option=26) [dll] sane_get_option_descriptor(handle=0xa25610,option=27) [dll] sane_get_option_descriptor(handle=0xa25610,option=28) [dll] sane_get_option_descriptor(handle=0xa25610,option=29) [dll] sane_get_option_descriptor(handle=0xa25610,option=30) [dll] sane_get_option_descriptor(handle=0xa25610,option=31) [dll] sane_get_option_descriptor(handle=0xa25610,option=32) [dll] sane_get_option_descriptor(handle=0xa25610,option=33) [dll] sane_get_option_descriptor(handle=0xa25610,option=34) [dll] sane_get_option_descriptor(handle=0xa25610,option=35) [dll] sane_get_option_descriptor(handle=0xa25610,option=36) [dll] sane_get_option_descriptor(handle=0xa25610,option=37) [dll] sane_get_option_descriptor(handle=0xa25610,option=38) [dll] sane_get_option_descriptor(handle=0xa25610,option=39) [dll] sane_get_option_descriptor(handle=0xa25610,option=40) [dll] sane_get_option_descriptor(handle=0xa25610,option=41) [dll] sane_get_option_descriptor(handle=0xa25610,option=42) [dll] sane_get_option_descriptor(handle=0xa25610,option=43) [dll] sane_get_option_descriptor(handle=0xa25610,option=44) [dll] sane_get_option_descriptor(handle=0xa25610,option=45) [dll] sane_get_option_descriptor(handle=0xa25610,option=46) [dll] sane_get_option_descriptor(handle=0xa25610,option=47) [dll] sane_get_option_descriptor(handle=0xa25610,option=48) [dll] sane_control_option(handle=0xa25610,option=38,action=0,value=0x60a670,info=(nil)) [dll] sane_control_option(handle=0xa25610,option=36,action=0,value=0x7fffe9d7f840,info=(nil)) [dll] sane_control_option(handle=0xa25610,option=39,action=0,value=0x60a674,info=(nil)) [dll] sane_control_option(handle=0xa25610,option=37,action=0,value=0x7fffe9d7f840,info=(nil)) [dll] sane_control_option(handle=0xa25610,option=36,action=0,value=0x7fffe9d81950,info=(nil)) [dll] sane_get_option_descriptor(handle=0xa25610,option=38) [dll] sane_control_option(handle=0xa25610,option=38,action=1,value=0x7fffe9d8194c,info=0x7fffe9d7f84c) [epson] setvalue(option = 38, value = 0x7fffe9d8194c) [epson] set = -32768.000000 scanimage: rounded value of br-x from -32768 to -32768 [dll] sane_control_option(handle=0xa25610,option=37,action=0,value=0x7fffe9d81950,info=(nil)) [dll] sane_get_option_descriptor(handle=0xa25610,option=39) [dll] sane_control_option(handle=0xa25610,option=39,action=1,value=0x7fffe9d8194c,info=0x7fffe9d7f84c) [epson] setvalue(option = 39, value = 0x7fffe9d8194c) [epson] set = -32768.000000 scanimage: rounded value of br-y from -32768 to -32768 [dll] sane_start(handle=0xa25610) [epson] sane_start() [epson] open_scanner() [epson] scanner is already open: fd = 0 [epson] sane_start: Setting data format to 1 bits [epson] send buf, size = 2 [epson] buf[0] 1b . [epson] buf[1] 44 D [sanei_usb] sanei_usb_write_bulk: trying to write 2 bytes [sanei_usb] 000 1B 44 .D [sanei_usb] sanei_usb_write_bulk: wanted 2 bytes, wrote 2 bytes [epson] w_cmd_count = 7 [epson] r_cmd_count = 6 [sanei_usb] sanei_usb_read_bulk: trying to read 1 bytes [sanei_usb] 000 15 . [sanei_usb] sanei_usb_read_bulk: wanted 1 bytes, got 1 bytes [epson] w_cmd_count = 7 [epson] r_cmd_count = 7 [epson] receive buf, expected = 1, got = 1 [epson] buf[0] 15 . [epson] sane_start: set_data_format failed: Invalid argument scanimage: sane_start: Invalid argument [dll] sane_cancel(handle=0xa25610) [dll] sane_close(handle=0xa25610) [epson] close_scanner(fd = 0) [epson] send buf, size = 2 [epson] buf[0] 1b . [epson] buf[1] 46 F [sanei_usb] sanei_usb_write_bulk: trying to write 2 bytes [sanei_usb] 000 1B 46 .F [sanei_usb] sanei_usb_write_bulk: wanted 2 bytes, wrote 2 bytes [epson] w_cmd_count = 8 [epson] r_cmd_count = 7 [sanei_usb] sanei_usb_read_bulk: trying to read 4 bytes [sanei_usb] 000 15 . [sanei_usb] sanei_usb_read_bulk: wanted 4 bytes, got 1 bytes [epson] w_cmd_count = 8 [epson] r_cmd_count = 8 [epson] receive buf, expected = 4, got = 1 [epson] buf[0] 15 . [epson] w_cmd_count = 8 [epson] r_cmd_count = 8 [epson] w_cmd_count = 8 [epson] r_cmd_count = 8 [sanei_usb] sanei_usb_close: closing device 0 [dll] sane_exit: exiting [dll] sane_exit: calling backend `epson's exit function [dll] sane_exit: finished emerge --info Portage 2.2_rc33 (default/linux/amd64/2008.0, gcc-4.3.3, glibc-2.9_p20081201-r2, 2.6.28-gentoo-r5 x86_64) ================================================================= System uname: Linux-2.6.28-gentoo-r5-x86_64-AMD_Athlon-tm-_64_X2_Dual_Core_Processor_4600+-with-gentoo-2.0.0 Timestamp of tree: Wed, 01 Jul 2009 05:30:01 +0000 app-shells/bash: 3.2_p39 dev-java/java-config: 2.1.7 dev-lang/python: 2.5.4-r2, 2.6.2 dev-util/cmake: 2.6.4 sys-apps/baselayout: 2.0.0-r2 sys-apps/openrc: 0.4.2-r1 sys-apps/sandbox: 1.6-r2 sys-devel/autoconf: 2.13, 2.63 sys-devel/automake: 1.5, 1.7.9-r1, 1.8.5-r3, 1.9.6-r2, 1.10.2 sys-devel/binutils: 2.19.1-r1 sys-devel/gcc-config: 1.4.1 sys-devel/libtool: 2.2.6a virtual/os-headers: 2.6.27-r2 ACCEPT_KEYWORDS="amd64" CBUILD="x86_64-pc-linux-gnu" CFLAGS="-march=athlon64 -O2 -pipe" CHOST="x86_64-pc-linux-gnu" -- http://www.wearablesmartsensors.com/ http://www.softwaresafety.net/ http://www.designer-iii.com/ http://www.unusualresearch.com/