[sane-devel] Vendor and product ids in description files

Henning Meier-Geinitz henning at meier-geinitz.de
Mon Jan 9 18:49:50 UTC 2006


Hi,

On 2006-01-09 16:23, Johannes Meixner wrote:
> > The keyword refers to the previous `:model', is optional,
> > and applicable for devices with :interface "USB" only,
> > and should be used only once per model.
> > Example: `:usbid "0x1234" "0x4321"'
> 
> "Should" is o.k. but please do not strictly forbid
> to have more than one ":usbid" for one ":model"
> and/or
> to have the same ":usbid" for more than one ":model".

"Should" means, that sane-desc won't emit a fatal error, but a warning
only :-) Currently, using :usbid (and e.g. :comment) more than once
just overwrites the previous entry and prints a warning.

I thought about using multiple usbids per model, but decided to not
allow it. The reason is that this would mean more complicated handling
in the HTML lists (or just stuff all the ids in one cell, which i want
to avoid).

Also my feeling is, that one usbid defines one scanner. If there is
another usbid with the same name, it's just another scanner. Actually,
this can be very real, as scanners with the same name and different
ids sometimes have completely different hardware.

> If the model name which the scanner reports via USB is
> different but unique, there can be two entries like:
> 
> :model "Fun Scanner 1000" ; what is on the scanner
> :usbid "0x1234" "0x4321"
> 
> :model "FS 1000" ; what the scanner reports via USB 
> :usbid "0x1234" "0x4321"

This is no problem at all. While reading the .desc file, there is no
test for unique usbids. You will just get multiple models with the
same usbids. E.g. try this search and you may understand why I hate
manufacturers who use the same ids for different scanners :-)
http://www.sane-project.org/cgi-bin/driver.pl?manu=&model=&bus=any&v=+05d&p=4002

Generally, I'd be careful using the USB strings provided by the
scanner itsself, however. Especially if they are too generic, this can
be misleading. E.g. there could be 10 models with USB string "600dpi
scanner" but only 5 are supported.
 
> If the model name which the scanner reports via USB is only
> a generic name, the following should be posible:

[...]
 
> :model "FS 1000 series" ; what the scanners report via USB
> :usbid "0x1234" "0x4321"
> :usbid "0x1234" "0x4322"

This is not possible, but there is a workaround:

:model "FS 1000 series" ; what the scanners report via USB
:usbid "0x1234" "0x4321"

:model "FS 1000 series" ; what the scanners report via USB
:usbid "0x1234" "0x4322"

Example:
http://www.sane-project.org/cgi-bin/driver.pl?manu=packard&model=%221200+Plus%22&bus=any&v=&p=

Bye,
  Henning



More information about the sane-devel mailing list