[sane-devel] HP scanjet 2400
Hello, I've set up a page with tools and doc at http://stef.dev.free.fr/sane/genesys which let you start up some work. I haven't got the log yet, since the time I created an email account to log in, the site is currently down. I'll try later to get it, so we know at which point the adaptation for the HP2400 will have to start. Regards, Stef
[sane-devel] Formulardaten
=== == Neuer Eintrag === --- -- Formular: 'adddev' --- 1. Your email address: 'fil5...@rambler.ru' 2. Manufacturer (e.g. Mustek): 'Hewlett Packard ' 3. Model name (e.g. ScanExpress 1200UB): 'Scanjet 3690' 4. Bus type: 'USB' 5. Vendor id (e.g. 0x001): '0x03f0' 6. Product id (e.g. 0x0002): '0x1405' 7. Chipset (e.g. lm9831): 'GL646_HP' 8. Comments (e.g. similar to Mustek 1234): 'Scanjet 3670c' 9. Data (e.g. sane-find-scanner -v -v): 'device descriptor of 0x03f0/0x1405 at 003:009 (Hewlett-Packard HP Scanjet Scanner) bLength 18 bDescriptorType 1 bcdUSB1.10 bDeviceClass 255 bDeviceSubClass 255 bDeviceProtocol 255 bMaxPacketSize0 8 idVendor 0x03F0 idProduct 0x1405 bcdDevice 1.00 iManufacturer 1 (Hewlett-Packard) iProduct 2 (HP Scanjet Scanner) iSerialNumber 12 (CN373S2558) bNumConfigurations1 configuration 0 bLength 9 bDescriptorType 2 wTotalLength 39 bNumInterfaces 1 bConfigurationValue 1 iConfiguration 0 () bmAttributes 192 (Self-powered) MaxPower 48 mA interface 0 altsetting 0 bLength9 bDescriptorType4 bInterfaceNumber 0 bAlternateSetting 0 bNumEndpoints 3 bInterfaceClass255 bInterfaceSubClass 255 bInterfaceProtocol 255 iInterface 0 () endpoint 0 bLength 7 bDescriptorType 5 bEndpointAddress 0x81 (in 0x01) bmAttributes 2 (bulk) wMaxPacketSize64 bInterval 0 ms bRefresh 0 bSynchAddress 0 endpoint 1 bLength 7 bDescriptorType 5 bEndpointAddress 0x02 (out 0x02) bmAttributes 2 (bulk) wMaxPacketSize64 bInterval 0 ms bRefresh 0 bSynchAddress 0 endpoint 2 bLength 7 bDescriptorType 5 bEndpointAddress 0x83 (in 0x03) bmAttributes 3 (interrupt) wMaxPacketSize1 bInterval 8 ms bRefresh 0 bSynchAddress 0'
[sane-devel] Fix for array subscript error in niash.c
Hello, the newest GNU compiler found an array subscript error in backend/niash.c of sane-backends-1.0.18, see https://bugzilla.novell.com/show_bug.cgi?id=246654 It happens because the arrays are defined with a size of optLast but actually optLast is not the last entry in the enumeration. Therefore I added an optEndOfList at the very end: --- backend/niash.c.orig2006-02-04 12:34:28.0 +0100 +++ backend/niash.c 2007-02-21 15:38:12.0 +0100 @@ -89,7 +89,9 @@ typedef enum optLamp, optCalibrate, - optGamma /* analog gamma = single number */ + optGamma, /* analog gamma = single number */ +/* have optEndOfList only to define arrays with sufficient size */ + optEndOfList } EOptionIndex; @@ -105,8 +107,8 @@ typedef union typedef struct { - SANE_Option_Descriptor aOptions[optLast]; - TOptionValue aValues[optLast]; + SANE_Option_Descriptor aOptions[optEndOfList]; + TOptionValue aValues[optEndOfList]; TScanParams ScanParams; THWParams HWParams; Kind Regards Johannes Meixner -- SUSE LINUX Products GmbH, Maxfeldstrasse 5, 90409 Nuernberg, Germany AG Nuernberg, HRB 16746, GF: Markus Rex
[sane-devel] Formulardaten
=== == Neuer Eintrag === --- -- Formular: 'adddev' --- 1. Your email address: 'k_gli...@o2.pl' 2. Manufacturer (e.g. Mustek): 'MICROTEK' 3. Model name (e.g. ScanExpress 1200UB): 'ScanMaker 3830' 4. Bus type: 'USB' 5. Vendor id (e.g. 0x001): '' 6. Product id (e.g. 0x0002): '' 7. Chipset (e.g. lm9831): '' 8. Comments (e.g. similar to Mustek 1234): '' 9. Data (e.g. sane-find-scanner -v -v): 'pc0-117:/proc/bus/input # sane-find-scanner -v -v This is sane-find-scanner from sane-backends 1.0.18 # sane-find-scanner will now attempt to detect your scanner. If the # result is different from what you expected, first make sure your # scanner is powered up and properly connected to your computer. searching for SCSI scanners: checking /dev/scanner... failed to open (Invalid argument) checking /dev/sg0... failed to open (Invalid argument) checking /dev/sg1... failed to open (Invalid argument) checking /dev/sg2... failed to open (Invalid argument) checking /dev/sg3... failed to open (Invalid argument) checking /dev/sg4... failed to open (Invalid argument) checking /dev/sg5... failed to open (Invalid argument) checking /dev/sg6... failed to open (Invalid argument) checking /dev/sg7... failed to open (Invalid argument) checking /dev/sg8... failed to open (Invalid argument) checking /dev/sg9... failed to open (Invalid argument) checking /dev/sga... failed to open (Invalid argument) checking /dev/sgb... failed to open (Invalid argument) checking /dev/sgc... failed to open (Invalid argument) checking /dev/sgd... failed to open (Invalid argument) checking /dev/sge... failed to open (Invalid argument) checking /dev/sgf... failed to open (Invalid argument) checking /dev/sgg... failed to open (Invalid argument) checking /dev/sgh... failed to open (Invalid argument) checking /dev/sgi... failed to open (Invalid argument) checking /dev/sgj... failed to open (Invalid argument) checking /dev/sgk... failed to open (Invalid argument) checking /dev/sgl... failed to open (Invalid argument) checking /dev/sgm... failed to open (Invalid argument) checking /dev/sgn... failed to open (Invalid argument) checking /dev/sgo... failed to open (Invalid argument) checking /dev/sgp... failed to open (Invalid argument) checking /dev/sgq... failed to open (Invalid argument) checking /dev/sgr... failed to open (Invalid argument) checking /dev/sgs... failed to open (Invalid argument) checking /dev/sgt... failed to open (Invalid argument) checking /dev/sgu... failed to open (Invalid argument) checking /dev/sgv... failed to open (Invalid argument) checking /dev/sgw... failed to open (Invalid argument) checking /dev/sgx... failed to open (Invalid argument) checking /dev/sgy... failed to open (Invalid argument) checking /dev/sgz... failed to open (Invalid argument) # No SCSI scanners found. If you expected something different, make sure that # you have loaded a kernel SCSI driver for your SCSI adapter. # Also you need support for SCSI Generic (sg) in your operating system. # If using Linux, try modprobe sg. searching for USB scanners: checking /dev/usb/scanner... failed to open (Invalid argument) checking /dev/usb/scanner0... failed to open (Invalid argument) checking /dev/usb/scanner1... failed to open (Invalid argument) checking /dev/usb/scanner2... failed to open (Invalid argument) checking /dev/usb/scanner3... failed to open (Invalid argument) checking /dev/usb/scanner4... failed to open (Invalid argument) checking /dev/usb/scanner5... failed to open (Invalid argument) checking /dev/usb/scanner5... failed to open (Invalid argument) checking /dev/usb/scanner7... failed to open (Invalid argument) checking /dev/usb/scanner8... failed to open (Invalid argument) checking /dev/usb/scanner9... failed to open (Invalid argument) checking /dev/usb/scanner10... failed to open (Invalid argument) checking /dev/usb/scanner11... failed to open (Invalid argument) checking /dev/usb/scanner12... failed to open (Invalid argument) checking /dev/usb/scanner13... failed to open (Invalid argument) checking /dev/usb/scanner14... failed to open (Invalid argument) checking /dev/usb/scanner15... failed to open (Invalid argument) checking /dev/usbscanner... failed to open (Invalid argument) checking /dev/usbscanner0... failed to open (Invalid argument) checking /dev/usbscanner1... failed to open (Invalid argument) checking /dev/usbscanner2... failed to open (Invalid argument) checking /dev/usbscanner3... failed to open (Invalid argument) checking /dev/usbscanner4... failed to open (Invalid argument) checking /dev/usbscanner5... failed to open (Invalid argument) checking /dev/usbscanner6... failed to open (Invalid argument) checking /dev/usbscanner7... failed to open (Invalid argument) checking /dev/usbscanner8... failed to open (Invalid argument) checking
[sane-devel] Fix for array subscript error in niash.c
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Johannes Meixner wrote: Hello, the newest GNU compiler found an array subscript error in backend/niash.c of sane-backends-1.0.18, see https://bugzilla.novell.com/show_bug.cgi?id=246654 It happens because the arrays are defined with a size of optLast but actually optLast is not the last entry in the enumeration. Therefore I added an optEndOfList at the very end: --- backend/niash.c.orig2006-02-04 12:34:28.0 +0100 +++ backend/niash.c 2007-02-21 15:38:12.0 +0100 @@ -89,7 +89,9 @@ typedef enum optLamp, optCalibrate, - optGamma /* analog gamma = single number */ + optGamma, /* analog gamma = single number */ +/* have optEndOfList only to define arrays with sufficient size */ + optEndOfList } EOptionIndex; @@ -105,8 +107,8 @@ typedef union typedef struct { - SANE_Option_Descriptor aOptions[optLast]; - TOptionValue aValues[optLast]; + SANE_Option_Descriptor aOptions[optEndOfList]; + TOptionValue aValues[optEndOfList]; TScanParams ScanParams; THWParams HWParams; (I am the original author of the niash backend but no longer the active maintainer.) The optLast option is indeed used to signify the number of available options. By placing an option behind optLast, it becomes invisible and inaccessible from the SANE API (at least that's the intention). This was a convenient hack to quickly enable or disable an experimental option in the beginning of the development of the backend. I think that adding an additional optEndOfList only complicates things more. How about simply removing the options beyond optLast (such that optLast is indeed the last option). They are not used in the backend anyway. Kind regards, Bertrik P.S. Nice to see that someone is actually checking sane-backends for compile warnings :P -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.2 (MingW32) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org iD8DBQFF3KGWETD6mlrWxPURArb0AJ4+JAG8dzFdKxJ6U3lHte99lP4vvwCfTQgo xKPX9XJ+lRJRTGqSxz3pZIE= =buu5 -END PGP SIGNATURE-