[sane-devel] Firmware info in description files

Johannes Meixner jsmeix at suse.de
Thu Jan 19 15:03:22 UTC 2006


Hello,

I would like to propose to add firmware info to the description
files.

Reason:
At the moment the supported/unsupported device lists do not
inform the user if he will have the trouble with firmware upload
and if yes how to get the firmware file.
Firmware information could be also in the :comment but then it
is more difficult for automated tools to extract the firmware
related information from the rest of the comment.


I suggest the following entry:
It refers to the previous :model and is optional.
Syntax:
:firmware "any string like in :comment"

Examples:

If no firmware upload is required, there is no :firmware keyword
or the value must be the empty string:
:firmware ""

If no details are known except that firmware upload is required
:firmware "required"

If an URL is known where to download the firmware:
:firmware "<A HREF=\"http://foo.bar/\">http://foo.bar/</A>"

If a file name on the driver CD is known:
:firmware "cdrom:/foo/bar.fw"

The examples are only some first ideas.
For download or files on the driver CD a much better URI syntax
may be useful.


Since some Suse Linux versions I add :firmware entries to the
description files when building our "sane" package and I include
the description files which are used by YaST because YaST must
know which models require firmware upload so that it can show
a user information.

At the moment our RPM spec file contains:
---------------------------------------------------------------------------
%install
.
.
.
# Add ':firmware "required"' entries for the respective scanners
# to the descriptions files so that YaST can show firmware upload
# related information to the user of such a scanner.
# This must be done after build because those entries are a SUSE
# specific extension.
# As far as we know all scanners which use the backend gt68xx
# and the related backend artec_eplus48u require a firmware upload,
# see "man sane-gt68xx" and
# http://www.meier-geinitz.de/sane/gt68xx-backend/
# and see "man sane-artec_eplus48u":
for b in gt68xx artec_eplus48u
do sed -i -e 's/^:model.*$/&\n:firmware "required"/' \
   %{buildroot}%{_datadir}/sane/descriptions/$b.desc
done
# As far as we know (almost) all USB scanners
# (but not the SCSI scanners) which use the backend snapscan
# require a firmware upload,
# see "man sane-snapscan" and http://snapscan.sourceforge.net/:
sed -i -e 's/^:interface "USB".*$/&\n:firmware "required"/' \
  %{buildroot}%{_datadir}/sane/descriptions/snapscan.desc
# Only the "SnapScan 1236u" needs no firmware upload
# (see Suse/Novell bug #73960):
sed -i -e '/:model "SnapScan 1236u"/,/:firmware "required"/s/required//' \ 
  %{buildroot}%{_datadir}/sane/descriptions/snapscan.desc
---------------------------------------------------------------------------

The result is for example in
/usr/share/sane/descriptions/snapscan.desc
---------------------------------------------------------------------------
:model "SnapScan 1236s"
:interface "SCSI"
:status :good
:comment "Optional ADF and transparency unit supported."

:model "SnapScan 1236u"
:interface "USB"
:firmware ""
:status :good
:comment "Optional ADF and transparency unit supported."

:model "SnapScan 1212u"
:interface "USB"
:firmware "required"
:status :good
---------------------------------------------------------------------------


Kind Regards
Johannes Meixner
-- 
SUSE LINUX Products GmbH, Maxfeldstrasse 5      Mail: jsmeix at suse.de
90409 Nuernberg, Germany                    WWW: http://www.suse.de/



More information about the sane-devel mailing list