[sane-devel] Epson Perfection 1650 on FreeBSD
Karl Heinz Kremer
khk at khk.net
Fri Jan 25 02:46:58 GMT 2002
On Thu, Jan 24, 2002 at 04:04:31PM -0800, JJ Behrens wrote:
> I'm not able to get scanimage to scan an image on my Epson Perfection 1650
> under FreeBSD. I get the following error message:
>
> tcp# scanimage -d "epson:/dev/uscanner0"
> scanimage: open of device epson:/dev/uscanner0 failed: Invalid argument
>
> I know that the device is recognized successfully, because when I plug it
> in, I get the following in /var/log/messages:
>
> Jan 24 15:41:04 tcp /kernel: uscanner0: EPSON EPSON Scanner, rev
> 1.00/1.08, addr 2
>
> I used truss to do a kernel trace while debugging was turned on,
> and I get the following:
>
> open("/dev/uscanner0",2,02001) = 3 (0x3)
> ioctl(3,CAMGETPASSTHRU,0xbfbfd614) ERR#22 'Invalid argument'
> close(3) = 0 (0x0)
> fstat(2,0xbfbfdc18) = 0 (0x0)
> [epson] write(2,0xbfbfd580,8) = 8 (0x8)
> attach: open failed: Invalid argument
>
> Notice that it's doing an ioctl call. It interesting that in
> /usr/src/sys/dev/usb/uscanner.c, uscannerioctl is defined as:
>
> int
> uscannerioctl(dev_t dev, u_long cmd, caddr_t addr, int flag, struct proc
> *p)
> {
> return (EINVAL);
> }
>
> Hence, it's not proper to do an IOCTL for USB scanners under FreeBSD.
Edit the file epson.c in Sane's backend directory. Search for the string
TEST_IOCTL and make sure that the #define statment is commented out.
This should disable the ioctl.
Karl Heinz
--
Karl Heinz Kremer khk at khk.net
PGP Key at http://www.khk.net/download/khk.asc
EPSON Sane Backend: http://www.khk.net
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 292 bytes
Desc: not available
URL: <http://alioth-lists.debian.net/pipermail/sane-devel/attachments/20020124/9979fa2d/attachment.sig>
More information about the sane-devel
mailing list