[sane-devel] snapscan: Support for BenQ 5150C

Benjamin Greiner sane-devel@lists.alioth.debian.org
Sun, 19 Dec 2004 14:05:40 +0100


Hi, 

I filled a Bug (#301085), but since there was no response, I'll try the 
mailinglist.

I own a BenQ Scanner 5150C and want to use it with Sane (on Gentoo Linux - 
current sane package version: 1.0.14-r6) 

The Scanner is recognized as: 

<< 
root:# sane-find-scanner 

# No SCSI scanners found. If you expected something different, make sure that 
# you have loaded a SCSI driver for your SCSI adapter. 

found USB scanner (vendor=0x04a5 [Color], product=0x2137 [ FlatbedScanner 22]) 
at libusb:001:004 
>> 

`scanimage -L` dind't find anything, so i added the followong lines to 
snapscan.conf (which seemed to be the correct backend for me): 

<< 
firmware /etc/sane.d/u55v009.bin 
usb 0x04a5 0x2137 
>> 

u55v009.bin is from the Windows Driver CD shipped with the scanner 

output of scanimage: 
<< 
root: # scanimage -L 
[sanei_debug] Setting debug level of snapscan to 2. 
device `snapscan:libusb:001:007' is a Acer FlatbedScanner40 flatbed scanner 
>> 

But if I call scanimage with any other parameter it segfaults after some time. 
After that no scanner is recognized until I pull the usb cable and plug it in 
again. 

<< 
root: # scanimage -T 
[sanei_debug] Setting debug level of snapscan to 2. 
Segmentation fault 

root: # scanimage -L 
[sanei_debug] Setting debug level of snapscan to 2. 
[snapscan] usb_read_status: scanner structure not set, returning default error 
[snapscan] mini_inquiry: snapscan_cmd command failed: Device busy 
[snapscan] snapscani_check_device: mini_inquiry failed with Device busy. 
[snapscan] usb_read_status: scanner structure not set, returning default error 

No scanners were identified. If you were expecting something different, 
check that the scanner is plugged in, turned on and detected by the 
sane-find-scanner tool (if appropriate). Please read the documentation 
which came with this software (README, FAQ, manpages). 

root: # # plugging usb... 

root: # scanimage -L 
[sanei_debug] Setting debug level of snapscan to 2. 
device `snapscan:libusb:001:008' is a Acer FlatbedScanner40 flatbed scanner 

>> 

The test backend works: 

<< 
root: # scanimage -d test -T 
scanimage: scanning image of size 157x196 pixels at 8 bits/pixel 
scanimage: acquiring gray frame, 8 bits/sample 
scanimage: reading one scanline, 157 bytes... PASS 
scanimage: reading one byte... PASS 
scanimage: stepped read, 2 bytes... PASS 
scanimage: stepped read, 4 bytes... PASS 
scanimage: stepped read, 8 bytes... PASS 
scanimage: stepped read, 16 bytes... PASS 
scanimage: stepped read, 32 bytes... PASS 
scanimage: stepped read, 64 bytes... PASS 
scanimage: stepped read, 128 bytes... PASS 
scanimage: stepped read, 256 bytes... PASS 
scanimage: stepped read, 255 bytes... PASS 
scanimage: stepped read, 127 bytes... PASS 
scanimage: stepped read, 63 bytes... PASS 
scanimage: stepped read, 31 bytes... PASS 
scanimage: stepped read, 15 bytes... PASS 
scanimage: stepped read, 7 bytes... PASS 
scanimage: stepped read, 3 bytes... PASS 
>> 

Can we add support for this scanner? I would be glad to help. 

Ben