kopia lustrzana https://gitlab.com/sane-project/backends
rodzic
30ab5e718a
commit
514da4e0d4
22
LEVEL2
22
LEVEL2
|
@ -1,4 +1,4 @@
|
||||||
Tue Nov 7 20:30:51 CET 2000
|
Tue Jun 3 10:22:33 1997
|
||||||
|
|
||||||
Here are some ideas under discussion for the next major revision of
|
Here are some ideas under discussion for the next major revision of
|
||||||
the SANE API:
|
the SANE API:
|
||||||
|
@ -16,23 +16,3 @@ the SANE API:
|
||||||
o Support for other multimedia types, such as audio. This probably
|
o Support for other multimedia types, such as audio. This probably
|
||||||
would also require adding a write() interface to the SANE API.
|
would also require adding a write() interface to the SANE API.
|
||||||
[Suggested by Erik Troan <ewt@redhat.com>.]
|
[Suggested by Erik Troan <ewt@redhat.com>.]
|
||||||
|
|
||||||
o add support for buttons etc. on the scanner/camera
|
|
||||||
|
|
||||||
o add support for sending messages from the backend to the frontend
|
|
||||||
(e.g. for warm up time)
|
|
||||||
|
|
||||||
o Change of the version number system (the current standard version
|
|
||||||
system is not really used in the SANE distribution).
|
|
||||||
|
|
||||||
o add more frame types
|
|
||||||
|
|
||||||
o add alpha channel so that RGBI scanners like Nikon LS-20 can
|
|
||||||
send infra-red info back to gimp for post-processing
|
|
||||||
|
|
||||||
o Might be nice if arbitrarily defined multiple channels, were possible.
|
|
||||||
Some way of indicating the number of channels possible, and some
|
|
||||||
details (wavelength, bandwidth, ...)
|
|
||||||
|
|
||||||
|
|
||||||
see sane-devel archive for more ideas
|
|
||||||
|
|
82
NEWS
82
NEWS
|
@ -1,86 +1,4 @@
|
||||||
-*-Mode: outline-*-
|
-*-Mode: outline-*-
|
||||||
|
|
||||||
New with 1.0.6, released 2001-11-05:
|
|
||||||
|
|
||||||
* New backends: gphoto2 (backend for gphoto2 supported cameras), mustek_usb
|
|
||||||
(for Mustek USB scanners 600CU, 1200CU(+), 1200UB).
|
|
||||||
* Updated backends: dc240 (v 0.0), epson (v 0.2.12), hp (0.95),
|
|
||||||
m3096g (v 1.11), microtek2 (v 0.95), mustek (v1.0-113), net (v 1.0.5),
|
|
||||||
pie (1.0-7), pnm (1.0-2), snapscan (v 1.4.0), umax (1.0-31), umax_pp (1).
|
|
||||||
* Added generic support for USB devices.
|
|
||||||
* Added USB support to sane-find-scanner.
|
|
||||||
* Code and documentation updates for HP UX compatibility.
|
|
||||||
* Documentation updates.
|
|
||||||
* Bugfixes.
|
|
||||||
|
|
||||||
New with 1.0.5, released 2001-07-01:
|
|
||||||
|
|
||||||
* New backends: bh (Bell+Howell Copiscan II series), dc240 (Kodak DC240
|
|
||||||
Digital Camera), sm3600 (Microtek ScanMaker 3600), umax_pp (Umax paralell
|
|
||||||
port scanners).
|
|
||||||
* Updated backends: artec (v0.5.16), dc25 (v1.2), dll (v1.0.3),
|
|
||||||
epson (v0.2.08), hp (v0.94), microtek (v0.12.3), microtek2(v0.9),
|
|
||||||
mustek (v1.0-107), nec (v0.12), net (v1.0.3), plustek (v0.39), pnm (v1.0.1),
|
|
||||||
snapscan (v1.2), tamarack (v0.5), umax (v1.0-28).
|
|
||||||
* Fixed security bug in saned.c that allowed access to scanner without
|
|
||||||
password.
|
|
||||||
* pnm isn't installed by default anymore due to security risks
|
|
||||||
* Linux-part of sanei_scsi.c was updated concerning buffersizes, devfs, and
|
|
||||||
kernel 2.4. More debug output.
|
|
||||||
* sanei_scsi_find_devices works on FreeBSD now.
|
|
||||||
* Added support for Solaris sgen SCSI driver.
|
|
||||||
* find-scanner was renamed to sane-find-scanner and is installed now. Further
|
|
||||||
more it has a man page now.
|
|
||||||
* There is a testsuite for sane, but only one test is implemented yet.
|
|
||||||
* Better output about versions of backends and frontends.
|
|
||||||
* There is a man page for SANE now (sane(7)).
|
|
||||||
* Install all available documentation.
|
|
||||||
* Bugfixes.
|
|
||||||
|
|
||||||
|
|
||||||
New with 1.0.4, released 2000-12-21:
|
|
||||||
|
|
||||||
* New backends: as6e, nec, pie.
|
|
||||||
* Updated backends: artec (v0.5.15), avision (v0.2.1), epson (v0.1.39),
|
|
||||||
hp (v0.93), mustek (v1.0-102), mustek_pp (v0.9-devel), plustek (v0.38),
|
|
||||||
sharp (v0.32), umax (v1.0-21).
|
|
||||||
* Moved frontends xscanimage and xcam to a new package (sane-frontends).
|
|
||||||
* Added authentification with encrypted passwords.
|
|
||||||
* Installation of shared libraries on AIX is supported now.
|
|
||||||
* Fixed compilation bugs on Irix and FreeBSD.
|
|
||||||
* Better debug output on platforms not supporting vararg macros.
|
|
||||||
* Better documentation about SANE devicenames.
|
|
||||||
* Bugfixes.
|
|
||||||
|
|
||||||
New with 1.0.3, released 2000-08-12:
|
|
||||||
|
|
||||||
* New backends: mustek_pp, plustek, st400, v4l.
|
|
||||||
* Updated backends: Artec (v0.5.14), Coolscan (v0.4.3), Epson (v0.1.33),
|
|
||||||
HP (v0.88), Mustek (v1.0-96), Sharp (v0.31), UMAX (v1.0-21).
|
|
||||||
* Removed backend info sagitta.desc due to lack of interest.
|
|
||||||
* Installing no longer depends on 'rev'.
|
|
||||||
* Added and structured documentation.
|
|
||||||
* Every backend has a man page now.
|
|
||||||
* Debug messages are now sent to syslog if stderr is a socket.
|
|
||||||
* New 16 bit support to scanimage.
|
|
||||||
* Bugfixes.
|
|
||||||
|
|
||||||
New with 1.0.2, released 2000-03-06:
|
|
||||||
* Aliased and hidden backend support.
|
|
||||||
* Port to UnixWare 2.x and UnixWare 7.
|
|
||||||
* New script 'sane-config' to help frontend developers.
|
|
||||||
* Added Ricoh IS50 support.
|
|
||||||
* Updated backends: Artec (v0.5.13), CANON (v991108), DC-25 (1.2), HP
|
|
||||||
(v0.86), Microtek (0.12.0), Microtek2 (v0.8), UMAX (v1.0-build-18),
|
|
||||||
Epson (v0.1.15), Sharp (v0.30), sp15c (1.12) and m3096g (1.11).
|
|
||||||
* Automatic document feeder support for scanimage.
|
|
||||||
* New backend for Avision AV 630 CS.
|
|
||||||
* New Linux SCSI Generic driver.
|
|
||||||
* Upgraded to libtool 1.3.4
|
|
||||||
* GIMP compatibility patch.
|
|
||||||
* OS/2 patches.
|
|
||||||
* Bugfixes.
|
|
||||||
|
|
||||||
New with 1.01:
|
New with 1.01:
|
||||||
|
|
||||||
* Miscellaneous
|
* Miscellaneous
|
||||||
|
|
436
TODO
436
TODO
|
@ -1,419 +1,37 @@
|
||||||
TODO (2002-02-15)
|
----- todo:
|
||||||
|
|
||||||
******** todo ********
|
- all frontends: support depths > 8 bits/channel
|
||||||
|
- net: don't just ignore the byte-order for the image data (needed to
|
||||||
backends
|
|
||||||
--------
|
|
||||||
* Add new backends (?)
|
|
||||||
- hp4200 http://hp4200-backend.sourceforge.net/
|
|
||||||
- v4l2 http://video.inodes.org/sane-v4l2/
|
|
||||||
- Relisys Scorpio Super 3 SCSI II
|
|
||||||
Mark Plowman <sane-devel@plowman.xs4all.nl>
|
|
||||||
http://www.xs4all.nl/~plowman/
|
|
||||||
- Linux Handscanner Ioctl Interface scanner by Harald
|
|
||||||
Bauer <bauer-h@web.de>
|
|
||||||
- viceo (Visioneer OneTouch 8600)
|
|
||||||
http://www.littlecms.com/iphoto/otlinux.htm
|
|
||||||
- Genius Vivid Pro USB, Colorado USB 19200, Visioneer OneTouch 7600
|
|
||||||
IBM IdeaScan 2000 USB
|
|
||||||
http://homepages.paradise.net.nz/stevenel/scanner/
|
|
||||||
- Fujitsu M3091DCd support
|
|
||||||
Frederik Ramm <frederik@remote.org>
|
|
||||||
http://www.remote.org/frederik/projects/software/sane/
|
|
||||||
- Canon FB620S flatbed scanner and FS2710 film scanner
|
|
||||||
ftp://stthd0.pc.uni-koeln.de/pub/canon-1.08.tar.gz
|
|
||||||
Ulrich Deiters <ukd@xenon.pc.Uni-Koeln.DE>
|
|
||||||
- Hewlett-Packard ScanJet 3300C / 3400C and 4300C (wip)
|
|
||||||
http://sourceforge.net/projects/hp3300backend
|
|
||||||
|
|
||||||
* Update backends
|
|
||||||
- Combine all the Fujitsu backends into one single backend
|
|
||||||
|
|
||||||
* All backends should check for TL_X < BR_X and TL_Y < BR_Y to
|
|
||||||
avoid segfaults or even scanner damage. This should NOT be done
|
|
||||||
in sane_control_option, it should be possible to temporary set
|
|
||||||
TL_X > BR_X or TL_ > BR, otherwise it is hard for a frontend to
|
|
||||||
set the correct values.
|
|
||||||
|
|
||||||
* Use DBG(...) instead of fprintf(stderr, ...) or printf
|
|
||||||
- microtek
|
|
||||||
|
|
||||||
* qcam:
|
|
||||||
- implement auto mode for brightness and black-level (don't
|
|
||||||
just advertise it!) Actually, implement an auto "backend" instead
|
|
||||||
that can be plugged in front of any backend with brightness/contrast
|
|
||||||
etc controls
|
|
||||||
- figure out how/if to support bulb mode
|
|
||||||
- convert to use sanei_pio functions instead of direct port
|
|
||||||
access.
|
|
||||||
- The result of locking isn't checked --> does it make sense at all?
|
|
||||||
|
|
||||||
* dll: Rewrite to use libtool ltdl library
|
|
||||||
|
|
||||||
* dc210, dc240, gphoto2, and jpeg stuff: move sanei_* functions to sanei/
|
|
||||||
(if they are necessary).
|
|
||||||
|
|
||||||
* v4l: Problems (crash) with more than one video card. It looks like
|
|
||||||
the two different cards are identified as the same card.
|
|
||||||
|
|
||||||
* Fix backends where sane_exit() does not release memory allocated by
|
|
||||||
sane_get_devices().
|
|
||||||
- abaton
|
|
||||||
- agfafocus
|
|
||||||
- apple
|
|
||||||
- as6e
|
|
||||||
- avision
|
|
||||||
- bh
|
|
||||||
- canon
|
|
||||||
- coolscan
|
|
||||||
- dmc
|
|
||||||
- m3096
|
|
||||||
- microtek
|
|
||||||
- qcam
|
|
||||||
- ricoh
|
|
||||||
- s9036
|
|
||||||
- sharp
|
|
||||||
- sp15c
|
|
||||||
- tamarack
|
|
||||||
|
|
||||||
- etc?
|
|
||||||
|
|
||||||
* as6e: attach: memory (dev + dev-sane.name) isn't freed if driver isn't
|
|
||||||
found.
|
|
||||||
|
|
||||||
* avision: line 1393: word isn't freed sometimes (maybe if cp == line?)
|
|
||||||
|
|
||||||
* net: add IPv6 support.
|
|
||||||
|
|
||||||
doc
|
|
||||||
---
|
|
||||||
* Add doxygen documentation for the remaining sanei files:
|
|
||||||
- sanei_pa4s2.h
|
|
||||||
- sanei_pio.h
|
|
||||||
- sanei_pv8630.h
|
|
||||||
- sanei_scsi.h
|
|
||||||
- sanei_wire.h
|
|
||||||
|
|
||||||
* sane.tex: Define the return values for sane_init? Define the
|
|
||||||
consequences if sane_init doesn't return SANE_STATUS_GOOD.
|
|
||||||
|
|
||||||
* sane.tex: Add a warning/explanation about problems with
|
|
||||||
sane_get_select_fd, Unix select() calls and sane_cancel.
|
|
||||||
|
|
||||||
* sane.tex: Add new sane.type = "film scanner". Check the other well known
|
|
||||||
strings for completeness.
|
|
||||||
|
|
||||||
* sane-backends.html should state more clearly which backends are included
|
|
||||||
in the distribution.
|
|
||||||
|
|
||||||
frontends
|
|
||||||
---------
|
|
||||||
* saned:
|
|
||||||
- saned times out after 60 minutes. Check if the
|
|
||||||
watchdog timer is really necessary (e.g. to avoid blocking scanners
|
|
||||||
by one user). Maybe add a command line option to saned to set the
|
|
||||||
timeout. Otherwise turn on TCP keep alive (where available) and
|
|
||||||
(maybe) check the connection from server side.
|
|
||||||
- Add IPv6 support.
|
|
||||||
|
|
||||||
* scanimage: Add i18n (NLS) support?
|
|
||||||
|
|
||||||
[the remaining entries have been moved to the sane-frontends package]
|
|
||||||
|
|
||||||
sanei
|
|
||||||
-----
|
|
||||||
* sanei_scsi: Think about a completely new interface. Details are in
|
|
||||||
http://www.mostang.com/pipermail/sane-devel/2002-January/001995.html .
|
|
||||||
|
|
||||||
* create sanei_parport_* and remove all inb, outb,... from all backends;
|
|
||||||
use libieee1284 if available (see
|
|
||||||
http://people.redhat.com/twaugh/libieee1284/). Or just include this
|
|
||||||
library into sane.
|
|
||||||
|
|
||||||
* Check if the device file has the right type before accessing it. E.g.
|
|
||||||
check for major/minor numbers to avoid accessing a USB file as SCSI
|
|
||||||
device. This is finished for sanei_scsi.c/Linux. Patches for other
|
|
||||||
platforms are welcome.
|
|
||||||
|
|
||||||
platform-specific
|
|
||||||
-----------------
|
|
||||||
* Keep config.guess and config.sub up-to-date.
|
|
||||||
|
|
||||||
* SCSI access doesn't seem to work on Linux/Sparc. See emails from
|
|
||||||
Tomislav Renic on sane-devel (2001-09-21).
|
|
||||||
|
|
||||||
* Really fix all the parport/inb/outb compilation issues which break
|
|
||||||
porting to some non-i386 platforms.
|
|
||||||
|
|
||||||
* Add AC_OBJEXT and AC_EXEEXT to configure.in for automatically adding
|
|
||||||
the correct extensions (e.g. for OS/2). Also update the Makefiles
|
|
||||||
accordingly.
|
|
||||||
|
|
||||||
* Add support for semaphores also for OS/2 (currently used in snapscan).
|
|
||||||
|
|
||||||
* Fix shared lib problem with NetBSD. Starting scanimage results in:
|
|
||||||
"Cannot open "../backend/.libs/libsane.so". However, scanadf works.
|
|
||||||
|
|
||||||
* Check if a new version of libtool can fix the above mentioned issues.
|
|
||||||
|
|
||||||
|
|
||||||
misc
|
|
||||||
----
|
|
||||||
* sane-config: add options "--exec-prefix=...." and "--prefix=..."
|
|
||||||
compareable to gtk-config
|
|
||||||
|
|
||||||
* Check include/sane/config.h.in for unnecessary macros.
|
|
||||||
|
|
||||||
* Add configure option to enable only the net backend for users without
|
|
||||||
local scanners. Install only sane-dll/sane-net (or even only sane-net).
|
|
||||||
Maybe something like --network-client-only or --disable-local-devices.
|
|
||||||
|
|
||||||
* Make output of sane-find-scanner more flexible. See scanimage -f for
|
|
||||||
details.
|
|
||||||
|
|
||||||
|
|
||||||
******** done ********
|
|
||||||
* make distclean should remove *.orig, *.old, .#*, *.tar.gz, and similar
|
|
||||||
files.
|
|
||||||
* Shared libs work with OpenBSD. However, they are named libsane.so.1.6
|
|
||||||
instead of 1.0.6. Is this correct?
|
|
||||||
* #include "../include/sane/config.h" should be the first include in every
|
|
||||||
file (see doc/sane-backend-writing.txt for the lalloca exception):
|
|
||||||
* Don't use -ansi for HPUX (see sane-devel).
|
|
||||||
* Don't use exit() in backends.
|
|
||||||
* sanei_scsi: Check return values of req_wait and cmd in case of
|
|
||||||
SCSI DEVICE BUSY. Better specification of the behaviour of sanei_scsi
|
|
||||||
functions (e.g. return values, timeout 10 min versus 1 min)?
|
|
||||||
* Documentation for sanei API
|
|
||||||
* Fix missing or wrong links to backend homepages (*.desc). If a homepage
|
|
||||||
doesn't exist, add a contact address (where available).
|
|
||||||
* Check all backends which use fork/kill for the kill (-1,...) bug
|
|
||||||
first found in the microtek2 backend.
|
|
||||||
* Add support for qt NLS (msg2qm) if possible without too much hassle.
|
|
||||||
* Add new backend primax http://primax.sourceforge.net/ (won't be ever a
|
|
||||||
real sane backend)
|
|
||||||
* qcam: Check file handling in /tmp.
|
|
||||||
* Add a check in the frontends if the backend delivers more data than
|
|
||||||
it announced by sane_get_parameters to avoid segfaults with bad
|
|
||||||
backends?
|
|
||||||
* Add installation procedure for translations of SANE backend's options.
|
|
||||||
* check memory leaks (checked with purify and mtrace (from glibc)):
|
|
||||||
* Test SANE on different os/platforms, fix possible compilation problems
|
|
||||||
Test methods: scanimage -d pnm:0 --filename=file.pnm -T
|
|
||||||
scanimage -d net:localhost:pnm:0 --filename=file.pnm -T
|
|
||||||
(start saned by inetd or saned -d before testing)
|
|
||||||
xscanimage / gimp with xscanimage plugin (where available)
|
|
||||||
All the above with shared and static libraries.->backend-writing.txt
|
|
||||||
* Remove compiler warnings (>300 warnings even in disable-warnings mode,
|
|
||||||
>700 with --enable-warnings)) ->backend-writing.txt
|
|
||||||
* Use #include "../include/sane/..." instead of #include <sane...>
|
|
||||||
->backend-writing.txt
|
|
||||||
* Use #include "../include/lalloca.h" instead of #include <lalloca.h>
|
|
||||||
->backend-writing.txt
|
|
||||||
* Update backend manpages (->backend-writing.txt).
|
|
||||||
* Add description of --enable-parport-directio.
|
|
||||||
* saned: Add documentation about the data connection.
|
|
||||||
* UMAX Astra 1220U backend
|
|
||||||
http://umax1220u-sane.sourceforge.net/
|
|
||||||
* There seems to be yet another race condition or other source for
|
|
||||||
freezes in saned or net. Wheile scanning with pnm and auth, scanimage
|
|
||||||
freezes. Last message from saned: "process_request: got request 2".
|
|
||||||
* Split configure option --enable-directio into --enable-scsi-directio and
|
|
||||||
--enable-parport-directio to avoid confusion. Also add appropriate
|
|
||||||
documentation.
|
|
||||||
* sanei_usb: Add sanei_usb_control_msg.
|
|
||||||
* Add support for PV8630 USB chipset (as sanei interface):
|
|
||||||
* Fix libsocket problem (OS/2). libsocket must be linked when testing for
|
|
||||||
libsyslog.
|
|
||||||
* Add bearpaw backend (Mustek BearPaw 1200 + maybe 2400)
|
|
||||||
(will be supported by plustek backend)
|
|
||||||
* Must -ldl be added to sane-config.in?
|
|
||||||
* Use @LIBDIR@, @CONFIGDIR@ and the other @@ macros to refer to paths.
|
|
||||||
These are updated when installing to a non-standard prefix.
|
|
||||||
* net: cancel doesn't work over the net at least with pnm and mustek.
|
|
||||||
* add Jochen Eisinger's net.c and sanei_wire.c fixes/additions.
|
|
||||||
* net.c: don't just ignore the byte-order for the image data (needed to
|
|
||||||
support depths > 8 bits/channel)
|
support depths > 8 bits/channel)
|
||||||
* saned seems to have problems checking the peer name of incoming
|
- mustek: for 3-pass scanners, it is said that xscanimage doesn't update
|
||||||
connections. This happens at least with glibc 2.2.4 if the
|
the scan progress bar properly between scans; it is said to stop at
|
||||||
name in saned.conf is not fully qualified. See sane-devel
|
90%, start the next pass, and once the next pass has started, it moves
|
||||||
"saned.conf hostname format".
|
on to 100% and the progress bar disappears at that point
|
||||||
* If you mention sane-devel, also mention the website concerning
|
- man pages for xcam, and the API functions
|
||||||
subscription (http://www.mostang.com/sane/mail.html), because you can't
|
- xscanimage: provide both scale and textentry for ranges (make new widget)
|
||||||
write to sane-devel without subscribing.
|
- xcam: provide access to option doc strings and allow disabling of
|
||||||
Or use your own mail address in the manual page.
|
advanced options and tooltips
|
||||||
* Check for logical errors and spelling
|
- xscanimage: scanning of images whose heights is not known a priori is not
|
||||||
* Check .desc files:
|
supported yet; this is going to be important for handheld scanners
|
||||||
* Check for formatting bugs in manual pages:
|
- qcam: implement auto mode for brightness and black-level (don't
|
||||||
* Use #include "../include/assert.h" instead of #include <assert.h> to
|
just advertise it!) Actually, implement an auto "backend" instead
|
||||||
avoid problem with shared libraries on AIX.
|
that can be plugged in front of any backend with brightness/contrast
|
||||||
* scanimage: Maybe add ADF extensions from Caskey Dickson (or add them to
|
etc controls
|
||||||
scanadf if necessary).
|
- qcam: figure out how/if to support bulb mode
|
||||||
* Add Mustek USB backend (1200UB, 1200CU, 1200CU Plus)
|
- xcam: add dithering and support for SANE depths other than 8 bit (test
|
||||||
http://www.meier-geinitz.de/sane/
|
with Mustek backend, for example)
|
||||||
Henning Meier-Geinitz <henning@meier-geinitz.de>
|
- xcam: add recording feature (e.g., GIF, JPG, or MPEG)
|
||||||
* Add USB support for sane-find-scanner.
|
- dll: make it robust against against it being listed in the configuration
|
||||||
* move .desc files for backends that are not included in SANE to
|
|
||||||
different directory (e.g. backends and external-backends)?
|
|
||||||
* create sanei_usb.* (maybe containing access for libusb and direct access
|
|
||||||
for usb device files)? (sane-1.0.6)
|
|
||||||
* Add sane-usb manpage
|
|
||||||
* Check net/saned
|
|
||||||
- sometimes saned+net freezes right after a scan (is this still
|
|
||||||
occuring 2001-06-04?)
|
|
||||||
* add warning when prefix dir is not listed in /etc/ld.so.conf on
|
|
||||||
linux systems may be there is a general way to test this if the
|
|
||||||
destination library directory is in the search path of the
|
|
||||||
linker. [The correct fix is to use -R (on Solaris) and -rpath
|
|
||||||
(on the rest?) to include the dynamic link path in the binaries
|
|
||||||
/ libraries. pere 2001-02-09 -- I believe this is partly fixed
|
|
||||||
in tools/sane-config.in 2001-05-18]
|
|
||||||
* Add links to sane(7) in all maual pages
|
|
||||||
* Check AIX/gcc shared lib loading problem: When starting scanimage,
|
|
||||||
only dll is loaded.
|
|
||||||
Backend libraries can't be loaded:
|
|
||||||
[dll] load: dlopen() failed (Symbol resolution failed for
|
|
||||||
/tmp/sane-bin/lib/sane/libsane-umax.so.1 because:
|
|
||||||
Symbol __eprintf (number 55) is not exported from dependent
|
|
||||||
module scanimage.
|
|
||||||
This happens in most libraries. The reason is assert() e.g. in
|
|
||||||
sanei_scsci.c. As assert() is in libgcc.a it can't be linked at runtime.
|
|
||||||
* Don't export any other symbols than sane_* and sanei_*
|
|
||||||
* nec:
|
|
||||||
- Remove references to sharp backend (grep for "JX").
|
|
||||||
- Check for HAVE_SYS_SHM_H before including sys/shm.h and
|
|
||||||
disable shared memory support if necessary.
|
|
||||||
* lines like "if (config_line[len - 1] == '\n')" can cause segfaults and
|
|
||||||
should be removed (removing "\n" is already done in sanei_config_read).
|
|
||||||
This ist just a fast grep. Check all backends!
|
|
||||||
* add additions/bug fixes to microtek2 from Karsten Festag
|
|
||||||
<karsten.festag@t-online.de> (partially done)
|
|
||||||
* include snapscan updates http://sourceforge.net/projects/snapscan
|
|
||||||
* as6e: change :new status to :alpha, :beta, or :stable.
|
|
||||||
* Check Tru64 Unix compilation problems with u_int* types. They are already
|
|
||||||
defined in sys/bitypes.h but this file isn't checked with AC_CHECK_TYPE.
|
|
||||||
(-> include sys/bitypes.h in these cases).
|
|
||||||
* Fix HP-UX problems in isfdtype.c (and maybe others). sys/stat.h doesn't
|
|
||||||
seem to define stuct stat (not a bug, make was used instead of gmake).
|
|
||||||
* Polaroid SprintScan 35 LE [should be included into microtek]
|
|
||||||
* Maybe add script to deinstall existing sane versions
|
|
||||||
- make uninstall
|
|
||||||
- install sane-uninstall script. Advantage: uninstall possible
|
|
||||||
without sourcecode (I think that's not necessary because you usually
|
|
||||||
have the sourcecode of a newer version if you want to uninstall. hmg)
|
|
||||||
* Add sane manpage (this is work in progress: Henning Meier-Geinitz
|
|
||||||
<henning@meier-geinitz.de>)
|
|
||||||
- versioning system?
|
|
||||||
- SANE API (maybe summary only?)
|
|
||||||
- point to backends and other information?
|
|
||||||
* Add backend UMAX 1220P/2000P & HP 320C http://umax1220p.sourceforge.net
|
|
||||||
* install all documentation that's available
|
|
||||||
* Add a check for installed sane versions.
|
|
||||||
- Print a warning when already a sane version is installed
|
|
||||||
- If SANE is installed at a different location, ask user to
|
|
||||||
remove old installation first
|
|
||||||
* epson: backend tries to detect usb scanners by default. This breaks with
|
|
||||||
non-epson scanners like the LM9831 bases Mustek Bearpaw 1200. The epson
|
|
||||||
backend freezes if such a scanner is plugged in. Try to make the test safe
|
|
||||||
or don't test without user interaction.
|
|
||||||
* pnm: add more options for testing (e.g. arrays and read-only options)
|
|
||||||
* sanei_scsi.c: OS/2: struct param breaks compilation with --enable-warnings.
|
|
||||||
(probably fixed by testing for os2.h in configure).
|
|
||||||
* Check all manpages for references to find-scanner (->sane-find-scanner).
|
|
||||||
* net.c doesn't compile on Irix because socklen_t isn't known
|
|
||||||
* Add new backends: bh http://www.martoneconsulting.com/sane-bh.html
|
|
||||||
* Add manpage for find-scanner.
|
|
||||||
* Should find-scanner be installed?
|
|
||||||
* net backend segfaults sometimes when connected to localhost. Enabling
|
|
||||||
debug output sometimes prevents segfaults. Cause of the problem:
|
|
||||||
Copying SANE_TYPE_STRINGs up to their maximum size in
|
|
||||||
SANE_Option_Descriptor (strings may be shorter then size).
|
|
||||||
* Compilation of most backends break with OS/2 and gcc because the
|
|
||||||
option -ansi doesn't seem to like sigset_t ?
|
|
||||||
* Check for shm.h in configure
|
|
||||||
* Add a global PATH_MAX macro somewhere (config.h ?) if it's not defined
|
|
||||||
by the system.
|
|
||||||
* sanei_scsi.c: Add patch from FreeBSD ports (sanei_scsi_find_devices)
|
|
||||||
(after 1.0.4).
|
|
||||||
* update libtool versioning system
|
|
||||||
- in /usr/local/lib/libsane.la "installed=no" is set, isn't
|
|
||||||
"installed=yes" the correct entry?
|
|
||||||
* plustek-share.h: remove //
|
|
||||||
* as6e: Check result of stat for errors to avoid false recognitions of the
|
|
||||||
as6edriver.
|
|
||||||
* artec: O_SYNC is not Posix. Breaks compilation on FreeBSD and (maybe) OS/2.
|
|
||||||
* use strchr() instead of index() in mustek_pp to avoid problems when
|
|
||||||
icluding strings.h or string.h.
|
|
||||||
* Add test for PTAL to acinclude.m4/configure.in
|
|
||||||
* build on Irix fails because of problems with the jpeg library. If this
|
|
||||||
is removed in configure, build works. It complains about functions like
|
|
||||||
(typename) functionname (). It doesn't like the brackets which result
|
|
||||||
from expanding the macros EXTERN(x), METHODDEF(x), and GLOBAL(x) to
|
|
||||||
(x). Defining something like EXTERN(x) x seems to work. Same for dc210.c
|
|
||||||
Something like --disable-jpeg for configure would be nice.
|
|
||||||
* addition to hp backend (support for SCL-based HP OfficeJets)
|
|
||||||
http://hpoj.sourceforge.net
|
|
||||||
* Libtool:
|
|
||||||
- -version-info is used but with the current version number system
|
|
||||||
-release should be used. (We should not change the version syntax
|
|
||||||
within an existing sane-standard, so we leave this)
|
|
||||||
- look for AIX problems (overwriting shared libs with eachother
|
|
||||||
because all libs are named libsane.so.1) (solved)
|
|
||||||
- look for Irix/cc problems (program searches for libsane.so.2 instead
|
|
||||||
of libsane.so.1). (Patch works for existing sane standard)
|
|
||||||
* getopt.c and umax.c seem to use gettext? Can cause crash if frontends
|
|
||||||
are linked to libintl, too.
|
|
||||||
* libdl is used in dll backend but -ldl is not added to LDFLAGS?
|
|
||||||
* use strchr() instead of index() in sanei_auth, scanimage, saned
|
|
||||||
to avoid problems when icluding strings.h or string.h.
|
|
||||||
* Remove frontends (at least xscanimage/xcam) from distribution.
|
|
||||||
* build on AIX does only work for static libraries. The shared libraries
|
|
||||||
seem to overwrite each other.
|
|
||||||
* add sanei_authorize (function for all backends)
|
|
||||||
* make authorization_callback work in net-backend and saned. Try to
|
|
||||||
avoid plain text passwords?
|
|
||||||
* Add as6e http://as6edriver.sourceforge.net/
|
|
||||||
* stiff.c: Tiff header not written correctly: "Jaeger, Gerhard"
|
|
||||||
<gjaeger@sysgo.de> writes: When writing the TIFF header, you have to
|
|
||||||
specify the TAG "BitsPerSample", which tells a reader how many bits each
|
|
||||||
sample has. The current version only specifies one value (8 or 16). This
|
|
||||||
is wrong, as we have to specify one value for each channel (i.e for a
|
|
||||||
24bit RGB pic we must specify 8,8,8, see TIFF6.0 spec, [...]
|
|
||||||
* don't install sanei_* headers
|
|
||||||
* Add sane-pie (Pacific Image Electronics series of ScanAce SCSI scanners, and
|
|
||||||
the Devcom 9636/9630 BlackWidow) http://www.munton.demon.co.uk/sane
|
|
||||||
* configure --without-x doesn't work (doesn't matter when frontends
|
|
||||||
are removed from package)
|
|
||||||
* Create new package for frontends.
|
|
||||||
* 0 is white for sane in lineart and halftone, however, 0 is black for
|
|
||||||
the other modes. Possible reason: pnm data format. The SANE standard
|
|
||||||
doesn't talk about this (added point to SANE standard)
|
|
||||||
* add ADF and TA entries to .desc files (not done, probably webpage gets
|
|
||||||
too wide)
|
|
||||||
* check DBG problems for non gcc compilers:
|
|
||||||
- no backend name output
|
|
||||||
- only global debug level
|
|
||||||
* dll: make it robust against it being listed in the configuration
|
|
||||||
file (currently bad things will happen if dll attempts to load itself)
|
file (currently bad things will happen if dll attempts to load itself)
|
||||||
* scanimage: add information about backend:devicename in the man
|
- PREVIEW: maybe there should be an option to limit the preview
|
||||||
page and scanimage --help.
|
|
||||||
* scanimage: check if devicename starts with a / and print a warning
|
|
||||||
message
|
|
||||||
* scanimage: if no devices are detected print a message
|
|
||||||
* use sanei_config_read() instead of fgets()
|
|
||||||
* use #include "sane/..." instead of #include <sane/...>
|
|
||||||
* Update LEVEL2 file. Ideas:
|
|
||||||
* xscanimage: Fix "Gtk-CRITICAL **: file gtkmain.c: line 534 ..." bug
|
|
||||||
when no SANE devices found
|
|
||||||
+ PREVIEW: maybe there should be an option to limit the preview
|
|
||||||
scan to the selected area? YES => this will also make it easier
|
scan to the selected area? YES => this will also make it easier
|
||||||
to avoid the scan area selection to get confused when the user
|
to avoid the scan area selection to get confused when the user
|
||||||
resizes the preview area in a way that changes the aspect ratio;
|
resizes the preview area in a way that changes the aspect ratio;
|
||||||
in essence we want to allow for the preview-image to be a subregion
|
in essence we want to allow for the preview-image to be a subregion
|
||||||
of the preview-window (done in xsane)
|
of the preview-window
|
||||||
+ xcam: allow disabling of advanced options and tooltips
|
|
||||||
+ man page for xcam
|
+++++ done:
|
||||||
+ scanimage: support depths > 8 bits/channel
|
|
||||||
+ upgrade to GTK 1.2 (but stay backwards compatible to 1.0 if possible)
|
+ upgrade to GTK 1.2 (but stay backwards compatible to 1.0 if possible)
|
||||||
+ saned: check_host() consider using strncasecmp()
|
+ saned: check_host() consider using strncasecmp()
|
||||||
+ GTK: changing the length unit causes dirty pixels in the unit-labels
|
+ GTK: changing the length unit causes dirty pixels in the unit-labels
|
||||||
|
|
|
@ -1,15 +1,13 @@
|
||||||
;Kodak DC25 backend .desc file by Peter Fales
|
;Kodak DC25 backend .desc file by Peter Fales
|
||||||
|
|
||||||
:backend "dc25" ; name of backend
|
:backend "dc25" ; name of backend
|
||||||
:version "1.2" ; version of backend
|
:version "1.1" ; version of backend
|
||||||
:status :beta ; :alpha, :beta, :stable, :new
|
:status :alpha ; :alpha, :beta, :stable, :new
|
||||||
:manpage "sane-dc25" ; name of manpage (if it exists)
|
:manpage "sane-dc25" ; name of manpage (if it exists)
|
||||||
:url "mailto:peter@fales.com";
|
:url "http://www.megsinet.net/~psfales/DC-25.html";
|
||||||
:devicetype :stillcam ; start of a list of devices....
|
:devicetype :stillcam ; start of a list of devices....
|
||||||
:mfg "Kodak" ; Manufacturer
|
:mfg "Kodak" ; Manufacturer
|
||||||
:url "http://www.kodak.com/global/en/service/digCam/dc25/dc25.shtml";
|
:url "http://www.kodak.com/US/en/digital/cameras/dc25/";
|
||||||
:model "DC25" ;
|
:model "DC25" ;
|
||||||
:interface "Serial port"
|
|
||||||
:model "DC20" ;
|
:model "DC20" ;
|
||||||
:interface "Serial port"
|
:comment "DC-20 is untested!" ;
|
||||||
:comment "DC-20 untested by author but reported to work"
|
|
||||||
|
|
6524
backend/epson.c
6524
backend/epson.c
Plik diff jest za duży
Load Diff
|
@ -1,82 +1,27 @@
|
||||||
;
|
|
||||||
; SANE Backend specification file
|
|
||||||
;
|
|
||||||
; It's basically emacs-lisp --- so ";" indicates comment to end of line.
|
|
||||||
; All syntactic elements are keyword tokens, followed by a string or
|
|
||||||
; keyword argument, as specified.
|
|
||||||
;
|
|
||||||
; ":backend" *must* be specified.
|
|
||||||
; All other information is optional (but what good is the file without it?).
|
|
||||||
;
|
|
||||||
|
|
||||||
:backend "microtek2" ; name of backend
|
:backend "microtek2" ; name of backend
|
||||||
:version "0.95" ; version of backend
|
:version "0.6" ; version of backend
|
||||||
:status :alpha ; :alpha, :beta, :stable, :new
|
:status :alpha ; :alpha, :beta, :stable, :new
|
||||||
:manpage "sane-microtek2" ; name of manpage (if it exists)
|
:manpage "sane-microtek2" ; name of manpage (if it exists)
|
||||||
:url "http://home.t-online.de/home/karsten.festag/"
|
|
||||||
|
|
||||||
:devicetype :scanner ; start of a list of devices....
|
:devicetype :scanner ; start of a list of devices....
|
||||||
|
|
||||||
:mfg "Microtek" ; name a manufacturer
|
:mfg "Microtek" ; name a manufacturer
|
||||||
:url "http://www.microtek.com/"
|
:url "http://www.microtek.com/"
|
||||||
:model "ScanMaker E3plus"
|
:model "parallel models unsupported"
|
||||||
:interface "Parport"
|
:model "ScanMaker V300"
|
||||||
|
:model "ScanMaker V310"
|
||||||
|
:model "ScanMaker V600"
|
||||||
:model "ScanMaker E3plus" ; name models for above-specified mfg.
|
:model "ScanMaker E3plus" ; name models for above-specified mfg.
|
||||||
:interface "SCSI"
|
|
||||||
:model "ScanMaker X6"
|
:model "ScanMaker X6"
|
||||||
:interface "SCSI"
|
|
||||||
:model "ScanMaker X6EL"
|
:model "ScanMaker X6EL"
|
||||||
:interface "SCSI"
|
|
||||||
:model "ScanMaker X6USB"
|
|
||||||
:interface "USB"
|
|
||||||
:model "ScanMaker V300"
|
|
||||||
:interface "SCSI"
|
|
||||||
:model "ScanMaker V300"
|
|
||||||
:interface "Parport"
|
|
||||||
:model "ScanMaker V310"
|
|
||||||
:interface "SCSI"
|
|
||||||
:model "ScanMaker V310"
|
|
||||||
:interface "Parport"
|
|
||||||
:model "ScanMaker V600"
|
|
||||||
:interface "SCSI"
|
|
||||||
:model "ScanMaker V600"
|
|
||||||
:interface "Parport"
|
|
||||||
:model "ScanMaker 330"
|
:model "ScanMaker 330"
|
||||||
:interface "SCSI"
|
|
||||||
:model "ScanMaker 630"
|
:model "ScanMaker 630"
|
||||||
:interface "SCSI"
|
|
||||||
:model "ScanMaker 636"
|
:model "ScanMaker 636"
|
||||||
:interface "SCSI"
|
|
||||||
:model "ScanMaker 9600XL"
|
:model "ScanMaker 9600XL"
|
||||||
:interface "SCSI"
|
|
||||||
:comment "only flatbed mode ?"
|
:comment "only flatbed mode ?"
|
||||||
:model "Phantom 330CX"
|
|
||||||
:interface "Parport"
|
|
||||||
:model "SlimScan C3"
|
|
||||||
:interface "Parport"
|
|
||||||
:model "Phantom 636"
|
:model "Phantom 636"
|
||||||
:interface "SCSI"
|
|
||||||
:model "Phantom 636CX"
|
|
||||||
:interface "Parport"
|
|
||||||
:model "SlimScan C6"
|
|
||||||
:interface "USB"
|
|
||||||
:model "ScanMaker V6USL"
|
|
||||||
:interface "SCSI"
|
|
||||||
|
|
||||||
:mfg "Vobis"
|
:mfg "Vobis"
|
||||||
:url "http://www.vobis.de/"
|
:url "http://www.vobis.de/"
|
||||||
:model "HighScan" ; name models for above-specified mfg.
|
:model "HighScan" ; name models for above-specified mfg.
|
||||||
:interface "SCSI"
|
|
||||||
:comment "only E3plus based models"
|
:comment "only E3plus based models"
|
||||||
|
|
||||||
:mfg "Scanport"
|
|
||||||
:url "http://www.scanport.com/"
|
|
||||||
:model "SQ300"
|
|
||||||
:interface "Parport?"
|
|
||||||
:model "SQ2030"
|
|
||||||
:interface "Parport"
|
|
||||||
:model "SQ4836"
|
|
||||||
:interface "SCSI"
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
1118
backend/microtek2.h
1118
backend/microtek2.h
Plik diff jest za duży
Load Diff
6000
backend/mustek.c
6000
backend/mustek.c
Plik diff jest za duży
Load Diff
|
@ -9,71 +9,38 @@
|
||||||
;
|
;
|
||||||
|
|
||||||
:backend "mustek" ; name of backend
|
:backend "mustek" ; name of backend
|
||||||
:version "1.0-99" ; version of backend
|
:version "0.73" ; version of backend
|
||||||
:status :beta ; :alpha, :beta, :stable, :new
|
:status :beta ; :alpha, :beta, :stable, :new
|
||||||
:manpage "sane-mustek" ; name of manpage (if it exists)
|
:manpage "sane-mustek" ; name of manpage (if it exists)
|
||||||
:url "http://hmg.home.pages.de/sane/"
|
|
||||||
|
|
||||||
:devicetype :scanner
|
:devicetype :scanner
|
||||||
|
|
||||||
:mfg "Mustek" ; name a manufacturer
|
:mfg "Mustek" ; name a manufacturer
|
||||||
:url "http://www.mustek.com/"
|
:url "http://www.mustek.com/"
|
||||||
|
:model "MFC-600S" ; name models for above-specified mfg.
|
||||||
:model "Paragon MFS-6000CX"
|
:comment "1 pass; (f/w >= 1.01; scsi id MFC-06000CZ)"
|
||||||
:interface "SCSI"
|
:model "MFC-600CD" ; name models for above-specified mfg.
|
||||||
:comment "3-pass"
|
:comment "1 pass; (f/w >= 2.03; scsi id MFC-06000CZ)"
|
||||||
:model "Paragon MFS-12000CX"
|
:model "MFS-6000CX"
|
||||||
:interface "SCSI"
|
:comment "3 pass; (f/w >= 2.71; scsi id MSF-06000CX)"
|
||||||
:comment "3-pass"
|
:model "MSF-6000SP"
|
||||||
:model "Paragon MFC-600S"
|
:comment "1 pass; (f/w >= 3.12; scsi id MSF-06000SP)"
|
||||||
:interface "SCSI"
|
:model "MFS-8000SP"
|
||||||
:model "Paragon 600 II CD"
|
:comment "1 pass; (f/w >= 2.05; scsi id MSF-08000SP) lineart drops lines?"
|
||||||
:interface "SCSI"
|
:model "MFC-800S"
|
||||||
:model "ScanMagic 600 II SP"
|
:comment "1 pass; (f/w == 1.06; scsi id MFC-08000CZ) color fails?"
|
||||||
:interface "SCSI"
|
:model "MFS-1200SP"
|
||||||
:model "Paragon MFC-800S"
|
:comment "1 pass; (f/w == 1.00; scsi id MSF-12000SP)"
|
||||||
:interface "SCSI"
|
:model "MFS-1200SP"
|
||||||
:model "Paragon 800 II SP"
|
:comment "1 pass; (f/w == 1.07; scsi id MFS-12000SP)"
|
||||||
:interface "SCSI"
|
:model "MFS-1200SP"
|
||||||
:model "Paragon MFS-6000SP"
|
:comment "1 pass; (f/w == 1.02; scsi id MFS-12000SP) color fails?"
|
||||||
:interface "SCSI"
|
:model "MFS-12000CX"
|
||||||
:model "Paragon MFS-8000SP"
|
:comment "3 pass; (f/w == 2.71; scsi id MFS-12000CX)"
|
||||||
:interface "SCSI"
|
:model "SE-6000SP"
|
||||||
:model "Paragon MFS-1200SP"
|
:comment "1 pass; (f/w == ? ; scsi id C03 S10IDW)"
|
||||||
:interface "SCSI"
|
:model "SE-12000SP"
|
||||||
:model "Paragon MFS-12000SP"
|
:comment "1 pass; (f/w == 1.01; scsi id C06 S12IDW)"
|
||||||
:interface "SCSI"
|
|
||||||
:model "ScanExpress 6000SP"
|
|
||||||
:interface "SCSI"
|
|
||||||
:model "ScanExpress 12000SP"
|
|
||||||
:interface "SCSI"
|
|
||||||
:model "ScanExpress 12000SP Plus"
|
|
||||||
:interface "SCSI"
|
|
||||||
:model "Paragon 1200 III SP"
|
|
||||||
:interface "SCSI"
|
|
||||||
:model "ScanMagic 9636S"
|
|
||||||
:interface "SCSI"
|
|
||||||
:model "ScanMagic 9636S Plus"
|
|
||||||
:interface "SCSI"
|
|
||||||
:model "ScanExpress A3 SP"
|
|
||||||
:interface "SCSI"
|
|
||||||
:comment "Please test!"
|
|
||||||
:model "Paragon 1200 SP Pro"
|
|
||||||
:interface "SCSI"
|
|
||||||
:comment "Please test!"
|
|
||||||
:model "Paragon 1200 A3 Pro"
|
|
||||||
:interface "SCSI"
|
|
||||||
:comment "Please test!"
|
|
||||||
:model "Paragon 600 II N"
|
|
||||||
:interface "Proprietary"
|
|
||||||
:mfg "Trust" ; name a manufacturer
|
|
||||||
:url "http://www.trust-site.com"
|
|
||||||
:model "Imagery 1200 SP"
|
|
||||||
:interface "SCSI"
|
|
||||||
:model "Imagery 4800 SP"
|
|
||||||
:interface "SCSI"
|
|
||||||
:model "SCSI Connect 19200"
|
|
||||||
:interface "SCSI"
|
|
||||||
|
|
||||||
; :comment and :url specifiers are optional after :mfg, :model, :desc,
|
; :comment and :url specifiers are optional after :mfg, :model, :desc,
|
||||||
; and at the top-level.
|
; and at the top-level.
|
||||||
|
|
|
@ -1,7 +1,6 @@
|
||||||
/* sane - Scanner Access Now Easy.
|
/* sane - Scanner Access Now Easy.
|
||||||
Copyright (C) 1996, 1997 David Mosberger-Tang, 1998 Andreas Bolsch for
|
Copyright (C) 1996, 1997 David Mosberger-Tang, 1998 Andreas Bolsch for
|
||||||
extension to ScanExpress models version 0.5,
|
extension to ScanExpress models version 0.5
|
||||||
2000 Henning Meier-Geinitz
|
|
||||||
This file is part of the SANE package.
|
This file is part of the SANE package.
|
||||||
|
|
||||||
This program is free software; you can redistribute it and/or
|
This program is free software; you can redistribute it and/or
|
||||||
|
@ -38,42 +37,25 @@
|
||||||
|
|
||||||
If you write modifications of your own for SANE, it is your choice
|
If you write modifications of your own for SANE, it is your choice
|
||||||
whether to permit this exception to apply to your modifications.
|
whether to permit this exception to apply to your modifications.
|
||||||
If you do not wish that, delete this exception notice.
|
If you do not wish that, delete this exception notice. */
|
||||||
|
|
||||||
This file implements a SANE backend for Mustek and some Trust flatbed
|
|
||||||
scanners with SCSI or proprietary interface. */
|
|
||||||
|
|
||||||
#ifndef mustek_h
|
#ifndef mustek_h
|
||||||
#define mustek_h
|
#define mustek_h
|
||||||
|
|
||||||
#include "sane/config.h"
|
|
||||||
#include <sys/types.h>
|
#include <sys/types.h>
|
||||||
|
|
||||||
/* flag values */
|
/* flag values: */
|
||||||
/* scanner types */
|
#define MUSTEK_FLAG_SINGLE_PASS (1 << 0) /* single-pass scanner? */
|
||||||
#define MUSTEK_FLAG_THREE_PASS (1 << 0) /* three pass scanner */
|
#define MUSTEK_FLAG_ADF (1 << 1) /* automatic document feeder */
|
||||||
#define MUSTEK_FLAG_PARAGON_1 (1 << 1) /* Paragon series I scanner */
|
#define MUSTEK_FLAG_ADF_READY (1 << 2) /* paper present */
|
||||||
#define MUSTEK_FLAG_PARAGON_2 (1 << 2) /* Paragon series II (A4) scanner */
|
#define MUSTEK_FLAG_TA (1 << 3) /* transparency adapter */
|
||||||
#define MUSTEK_FLAG_SE (1 << 3) /* ScanExpress scanner */
|
#define MUSTEK_FLAG_USE_EIGHTS (1 << 4) /* use 1/8" lengths */
|
||||||
#define MUSTEK_FLAG_SE_PLUS (1 << 4) /* ScanExpress Plus scanner */
|
#define MUSTEK_FLAG_LD_FIX (1 << 5) /* need line-distance fix? */
|
||||||
#define MUSTEK_FLAG_PRO (1 << 5) /* Professional series scanner */
|
#define MUSTEK_FLAG_LD_MFS (1 << 6) /* MFS line-distance corr? */
|
||||||
#define MUSTEK_FLAG_N (1 << 6) /* N-type scanner (non SCSI) */
|
#define MUSTEK_FLAG_LD_NONE (1 << 7) /* no line-distance corr? */
|
||||||
/* additional equipment */
|
#define MUSTEK_FLAG_LINEART_FIX (1 << 8) /* lineart fix/hack */
|
||||||
#define MUSTEK_FLAG_ADF (1 << 7) /* automatic document feeder */
|
#define MUSTEK_FLAG_PP (1 << 9) /* //-port scanner? */
|
||||||
#define MUSTEK_FLAG_ADF_READY (1 << 8) /* paper present */
|
#define MUSTEK_FLAG_SE (1 << 10) /* ScanExpress model ? */
|
||||||
#define MUSTEK_FLAG_TA (1 << 9) /* transparency adapter */
|
#define MUSTEK_FLAG_DOUBLE_RES (1 << 11) /* MSF-06000CZ res. encoding */
|
||||||
/* line-distance correction */
|
|
||||||
#define MUSTEK_FLAG_LD_NONE (1 << 10) /* no line-distance corr */
|
|
||||||
#define MUSTEK_FLAG_LD_BLOCK (1 << 11) /* blockwise LD corr */
|
|
||||||
#define MUSTEK_FLAG_LD_N1 (1 << 12) /* LD corr for N-type v1 */
|
|
||||||
#define MUSTEK_FLAG_LD_N2 (1 << 13) /* LD corr for N-type v2 */
|
|
||||||
/* manual fixes */
|
|
||||||
#define MUSTEK_FLAG_LD_FIX (1 << 14) /* need line-distance fix? */
|
|
||||||
#define MUSTEK_FLAG_LINEART_FIX (1 << 15) /* lineart fix/hack */
|
|
||||||
#define MUSTEK_FLAG_USE_EIGHTS (1 << 16) /* use 1/8" lengths */
|
|
||||||
#define MUSTEK_FLAG_FORCE_GAMMA (1 << 17) /* force gamma table upload */
|
|
||||||
#define MUSTEK_FLAG_ENLARGE_X (1 << 18) /* need to enlarge x-res */
|
|
||||||
#define MUSTEK_FLAG_COVER_SENSOR (1 << 19) /* scanner can detect open cover */
|
|
||||||
|
|
||||||
/* source values: */
|
/* source values: */
|
||||||
#define MUSTEK_SOURCE_FLATBED 0
|
#define MUSTEK_SOURCE_FLATBED 0
|
||||||
|
@ -81,12 +63,9 @@
|
||||||
#define MUSTEK_SOURCE_TA 2
|
#define MUSTEK_SOURCE_TA 2
|
||||||
|
|
||||||
/* mode values: */
|
/* mode values: */
|
||||||
#define MUSTEK_MODE_LINEART (1 << 0) /* grayscale 1 bit / pixel */
|
#define MUSTEK_MODE_MULTIBIT (1 << 0) /* one-bit vs multi-bit */
|
||||||
#define MUSTEK_MODE_GRAY (1 << 1) /* grayscale 8 bits / pixel */
|
#define MUSTEK_MODE_COLOR (1 << 1) /* grayscale vs color */
|
||||||
#define MUSTEK_MODE_COLOR (1 << 2) /* color 24 bits / pixel */
|
#define MUSTEK_MODE_HALFTONE (1 << 2) /* use dithering? */
|
||||||
#define MUSTEK_MODE_HALFTONE (1 << 3) /* use dithering */
|
|
||||||
#define MUSTEK_MODE_GRAY_FAST (1 << 4) /* Pro series fast grayscale */
|
|
||||||
#define MUSTEK_MODE_COLOR_48 (1 << 5) /* color 48 bits / pixel */
|
|
||||||
|
|
||||||
enum Mustek_Option
|
enum Mustek_Option
|
||||||
{
|
{
|
||||||
|
@ -97,6 +76,7 @@ enum Mustek_Option
|
||||||
OPT_RESOLUTION,
|
OPT_RESOLUTION,
|
||||||
OPT_SPEED,
|
OPT_SPEED,
|
||||||
OPT_SOURCE,
|
OPT_SOURCE,
|
||||||
|
OPT_BACKTRACK,
|
||||||
OPT_PREVIEW,
|
OPT_PREVIEW,
|
||||||
OPT_GRAY_PREVIEW,
|
OPT_GRAY_PREVIEW,
|
||||||
|
|
||||||
|
@ -107,14 +87,9 @@ enum Mustek_Option
|
||||||
OPT_BR_Y, /* bottom-right y */
|
OPT_BR_Y, /* bottom-right y */
|
||||||
|
|
||||||
OPT_ENHANCEMENT_GROUP,
|
OPT_ENHANCEMENT_GROUP,
|
||||||
|
OPT_GRAIN_SIZE,
|
||||||
OPT_BRIGHTNESS,
|
OPT_BRIGHTNESS,
|
||||||
OPT_BRIGHTNESS_R,
|
|
||||||
OPT_BRIGHTNESS_G,
|
|
||||||
OPT_BRIGHTNESS_B,
|
|
||||||
OPT_CONTRAST,
|
OPT_CONTRAST,
|
||||||
OPT_CONTRAST_R,
|
|
||||||
OPT_CONTRAST_G,
|
|
||||||
OPT_CONTRAST_B,
|
|
||||||
OPT_CUSTOM_GAMMA, /* use custom gamma tables? */
|
OPT_CUSTOM_GAMMA, /* use custom gamma tables? */
|
||||||
/* The gamma vectors MUST appear in the order gray, red, green,
|
/* The gamma vectors MUST appear in the order gray, red, green,
|
||||||
blue. */
|
blue. */
|
||||||
|
@ -122,7 +97,6 @@ enum Mustek_Option
|
||||||
OPT_GAMMA_VECTOR_R,
|
OPT_GAMMA_VECTOR_R,
|
||||||
OPT_GAMMA_VECTOR_G,
|
OPT_GAMMA_VECTOR_G,
|
||||||
OPT_GAMMA_VECTOR_B,
|
OPT_GAMMA_VECTOR_B,
|
||||||
OPT_QUALITY_CAL,
|
|
||||||
OPT_HALFTONE_DIMENSION,
|
OPT_HALFTONE_DIMENSION,
|
||||||
OPT_HALFTONE_PATTERN,
|
OPT_HALFTONE_PATTERN,
|
||||||
|
|
||||||
|
@ -141,7 +115,6 @@ Option_Value;
|
||||||
typedef struct Mustek_Device
|
typedef struct Mustek_Device
|
||||||
{
|
{
|
||||||
struct Mustek_Device *next;
|
struct Mustek_Device *next;
|
||||||
SANE_String name;
|
|
||||||
SANE_Device sane;
|
SANE_Device sane;
|
||||||
SANE_Range dpi_range;
|
SANE_Range dpi_range;
|
||||||
SANE_Range x_range;
|
SANE_Range x_range;
|
||||||
|
@ -154,31 +127,13 @@ typedef struct Mustek_Device
|
||||||
int gamma_length;
|
int gamma_length;
|
||||||
/* values actually used by scanner, not necessarily the desired! */
|
/* values actually used by scanner, not necessarily the desired! */
|
||||||
int bpl, lines;
|
int bpl, lines;
|
||||||
/* what is needed for calibration (ScanExpress and Pro series)*/
|
/* what is needed for calibration */
|
||||||
struct
|
struct
|
||||||
{
|
{
|
||||||
int bytes;
|
int bytes;
|
||||||
int lines;
|
int lines;
|
||||||
unsigned char *buffer;
|
|
||||||
}
|
}
|
||||||
cal;
|
cal;
|
||||||
/* current and maximum buffer size used by the backend */
|
|
||||||
/* the buffer sent to the scanner is actually half of this size */
|
|
||||||
int buffer_size;
|
|
||||||
int max_buffer_size;
|
|
||||||
/* maximum size scanned in one block and corresponding lines */
|
|
||||||
int max_block_buffer_size;
|
|
||||||
int lines_per_block;
|
|
||||||
unsigned char *block_buffer;
|
|
||||||
|
|
||||||
/* firmware format: 0 = old, MUSTEK at pos 8; 1 = new, MUSTEK at
|
|
||||||
pos 36 */
|
|
||||||
int firmware_format;
|
|
||||||
/* firmware revision system: 0 = old, x.yz; 1 = new, Vxyz */
|
|
||||||
int firmware_revision_system;
|
|
||||||
/* For SE scanners: which resolutions are allowed in color mode */
|
|
||||||
|
|
||||||
const unsigned int *resolution_list;
|
|
||||||
}
|
}
|
||||||
Mustek_Device;
|
Mustek_Device;
|
||||||
|
|
||||||
|
@ -191,11 +146,8 @@ typedef struct Mustek_Scanner
|
||||||
Option_Value val[NUM_OPTIONS];
|
Option_Value val[NUM_OPTIONS];
|
||||||
SANE_Int gamma_table[4][256];
|
SANE_Int gamma_table[4][256];
|
||||||
SANE_Int halftone_pattern[64];
|
SANE_Int halftone_pattern[64];
|
||||||
SANE_Bool custom_halftone_pattern;
|
|
||||||
SANE_Int halftone_pattern_type;
|
|
||||||
|
|
||||||
int scanning;
|
int scanning;
|
||||||
int cancelled;
|
|
||||||
int pass; /* pass number */
|
int pass; /* pass number */
|
||||||
int line; /* current line number */
|
int line; /* current line number */
|
||||||
SANE_Parameters params;
|
SANE_Parameters params;
|
||||||
|
@ -208,7 +160,6 @@ typedef struct Mustek_Scanner
|
||||||
int fd; /* SCSI filedescriptor */
|
int fd; /* SCSI filedescriptor */
|
||||||
pid_t reader_pid; /* process id of reader */
|
pid_t reader_pid; /* process id of reader */
|
||||||
int pipe; /* pipe to reader process */
|
int pipe; /* pipe to reader process */
|
||||||
long start_time; /* at this time the scan started */
|
|
||||||
|
|
||||||
/* scanner dependent/low-level state: */
|
/* scanner dependent/low-level state: */
|
||||||
Mustek_Device *hw;
|
Mustek_Device *hw;
|
||||||
|
@ -221,11 +172,11 @@ typedef struct Mustek_Scanner
|
||||||
int peak_res;
|
int peak_res;
|
||||||
int dist[3]; /* line distance */
|
int dist[3]; /* line distance */
|
||||||
int index[3]; /* index for R/G/B color assignment */
|
int index[3]; /* index for R/G/B color assignment */
|
||||||
int quant[3]; /* for resolution correction */
|
int quant[3]; /* for resolution correection */
|
||||||
int saved[3]; /* number of saved color lines */
|
int saved[3]; /* number of saved color lines */
|
||||||
/* these are used for SE, MFS and N line-distance correction: */
|
/* these are used for SE, MFS and pp line-distance correction: */
|
||||||
unsigned char *buf[3];
|
char *buf[3];
|
||||||
/* these are used for N line-distance correction only: */
|
/* these are used for parallel-port line-distance correction only: */
|
||||||
int ld_line; /* line # currently processed in ld-correction */
|
int ld_line; /* line # currently processed in ld-correction */
|
||||||
int lmod3; /* line # modulo 3 */
|
int lmod3; /* line # modulo 3 */
|
||||||
}
|
}
|
||||||
|
|
|
@ -360,8 +360,8 @@ transfer_data_diff (u_char * buf, SnapScan_Scanner * pss)
|
||||||
}
|
}
|
||||||
|
|
||||||
/* $Log$
|
/* $Log$
|
||||||
* Revision 1.1 1999/08/09 18:05:54 pere
|
* Revision 1.1.1.1 1999/08/09 18:05:54 pere
|
||||||
* Initial revision
|
* Wiped old repository. Imported v1.0.1.
|
||||||
*
|
*
|
||||||
* Revision 1.1.3.1 1998/03/10 23:42:01 eblot
|
* Revision 1.1.3.1 1998/03/10 23:42:01 eblot
|
||||||
* Debugging: large windows, color preview
|
* Debugging: large windows, color preview
|
||||||
|
|
|
@ -3622,8 +3622,8 @@ sane_get_select_fd (SANE_Handle h, SANE_Int * fd)
|
||||||
|
|
||||||
|
|
||||||
/* $Log$
|
/* $Log$
|
||||||
* Revision 1.1 1999/08/09 18:05:49 pere
|
* Revision 1.1.1.1 1999/08/09 18:05:49 pere
|
||||||
* Initial revision
|
* Wiped old repository. Imported v1.0.1.
|
||||||
*
|
*
|
||||||
* Revision 1.40 1998/12/16 18:43:06 charter
|
* Revision 1.40 1998/12/16 18:43:06 charter
|
||||||
* Fixed major version problem precipitated by release of SANE-1.00.
|
* Fixed major version problem precipitated by release of SANE-1.00.
|
||||||
|
|
|
@ -231,8 +231,8 @@ SnapScan_Scanner;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
/* $Log$
|
/* $Log$
|
||||||
* Revision 1.1 1999/08/09 18:05:53 pere
|
* Revision 1.1.1.1 1999/08/09 18:05:53 pere
|
||||||
* Initial revision
|
* Wiped old repository. Imported v1.0.1.
|
||||||
*
|
*
|
||||||
* Revision 1.25 1998/12/16 18:40:53 charter
|
* Revision 1.25 1998/12/16 18:40:53 charter
|
||||||
* Commented the INOPERATIVE define to get rid of spurious brightness
|
* Commented the INOPERATIVE define to get rid of spurious brightness
|
||||||
|
|
|
@ -10,209 +10,117 @@
|
||||||
;
|
;
|
||||||
|
|
||||||
:backend "umax" ; name of backend
|
:backend "umax" ; name of backend
|
||||||
:version "1.0-31" ; version of backend
|
:version "1.01-build-3" ; version of backend
|
||||||
:status :stable ; :alpha, :beta, :stable, :new
|
:status :stable ; :alpha, :beta, :stable, :new
|
||||||
:manpage "sane-umax" ; name of manpage (if it exists)
|
:manpage "sane-umax" ; name of manpage (if it exists)
|
||||||
:url "http://www.rauch-domain.de/sane-umax/index.html" ; backend's web page
|
:url "http://www.wolfsburg.de/~rauch/sane/sane-umax.html" ; backend's web page
|
||||||
|
|
||||||
:devicetype :scanner ; start of a list of devices....
|
:devicetype :scanner ; start of a list of devices....
|
||||||
; other types: :stillcam, :vidcam,
|
; other types: :stillcam, :vidcam,
|
||||||
; :meta, :api
|
; :meta, :api
|
||||||
|
|
||||||
:mfg "UMAX" ; name a manufacturer
|
:mfg "UMAX" ; name a manufacturer
|
||||||
|
:url "http://support.umax.co.uk/"
|
||||||
:url "http://www.umax.com/"
|
:url "http://www.umax.com/"
|
||||||
:url "http://support.umax.com/"
|
:url "http://support.umax.com/"
|
||||||
:url "http://www.umax.de/"
|
:url "http://www.umax.de/"
|
||||||
:url "http://www.umax.com.tw/"
|
:url "http://www.umax.com.tw/"
|
||||||
:url "http://www.umaxweb.com.tw/"
|
:url "http://www.umaxweb.com.tw/"
|
||||||
:url "http://support.umax.co.uk/"
|
|
||||||
:model "parallel scanners" ; name models for above-specified mfg.
|
:model "parallel scanners" ; name models for above-specified mfg.
|
||||||
:interface "Parport"
|
:comment "Not supported!!!"
|
||||||
:comment "Not supported - see backend umax_pp"
|
|
||||||
:model "USB scanners"
|
|
||||||
:interface "USB"
|
|
||||||
:comment "Not supported - see backend umax1220u"
|
|
||||||
:model "firewire scanners"
|
|
||||||
:interface "Firewire"
|
|
||||||
:comment "not tested"
|
|
||||||
:model "Vista S6"
|
:model "Vista S6"
|
||||||
:interface "SCSI"
|
|
||||||
:comment "OK"
|
:comment "OK"
|
||||||
:model "Vista S6E"
|
:model "Vista S6E"
|
||||||
:interface "SCSI"
|
|
||||||
:comment "OK"
|
:comment "OK"
|
||||||
:model "UMAX S-6E"
|
:model "UMAX S-6E"
|
||||||
:interface "SCSI"
|
|
||||||
:comment "OK"
|
:comment "OK"
|
||||||
:model "UMAX S-6EG"
|
:model "UMAX S-6EG"
|
||||||
:interface "SCSI"
|
|
||||||
:comment "OK"
|
:comment "OK"
|
||||||
:model "Vista-S8"
|
:model "Vista-S8"
|
||||||
:interface "SCSI"
|
:comment "Not tested"
|
||||||
:comment "OK"
|
|
||||||
:model "Supervista S-12"
|
:model "Supervista S-12"
|
||||||
:interface "SCSI"
|
|
||||||
:comment "OK"
|
:comment "OK"
|
||||||
:model "UMAX S-12"
|
:model "UMAX S-12"
|
||||||
:interface "SCSI"
|
|
||||||
:comment "OK"
|
:comment "OK"
|
||||||
:model "UMAX S-12G"
|
:model "UMAX S-12G"
|
||||||
:interface "SCSI"
|
|
||||||
:comment "OK"
|
:comment "OK"
|
||||||
:model "Astra 600S"
|
:model "Astra 600S"
|
||||||
:interface "SCSI"
|
|
||||||
:comment "OK"
|
:comment "OK"
|
||||||
:model "Astra 610S"
|
:model "Astra 610S"
|
||||||
:interface "SCSI"
|
|
||||||
:comment "OK"
|
:comment "OK"
|
||||||
:model "Astra 1200S"
|
:model "Astra 1200S"
|
||||||
:interface "SCSI"
|
|
||||||
:comment "OK"
|
:comment "OK"
|
||||||
:model "Astra 1220S"
|
:model "Astra 1220S"
|
||||||
:interface "SCSI"
|
|
||||||
:comment "OK"
|
:comment "OK"
|
||||||
:model "Astra 2100S"
|
|
||||||
:interface "SCSI"
|
|
||||||
:comment "OK"
|
|
||||||
:model "Astra 2200 (SU)"
|
|
||||||
:interface "SCSI"
|
|
||||||
:comment "OK"
|
|
||||||
:model "Astra 2400S"
|
|
||||||
:interface "SCSI"
|
|
||||||
:comment "OK"
|
|
||||||
:model "Mirage D-16L"
|
|
||||||
:interface "SCSI"
|
|
||||||
:comment "OK"
|
|
||||||
:model "Mirage II"
|
|
||||||
:interface "SCSI"
|
|
||||||
:comment "OK"
|
|
||||||
:model "Mirage IIse"
|
|
||||||
:interface "SCSI"
|
|
||||||
:comment "Not tested"
|
|
||||||
:model "PSD"
|
|
||||||
:interface "SCSI"
|
|
||||||
:comment "OK"
|
|
||||||
:model "PowerLook"
|
|
||||||
:interface "SCSI"
|
|
||||||
:comment "Not tested"
|
|
||||||
:model "PL-II"
|
|
||||||
:interface "SCSI"
|
|
||||||
:comment "Not tested"
|
|
||||||
:model "PowerLook III"
|
|
||||||
:interface "SCSI"
|
|
||||||
:comment "OK"
|
|
||||||
:model "PowerLook 2000"
|
|
||||||
:interface "SCSI"
|
|
||||||
:comment "Not tested"
|
|
||||||
:model "PowerLook 3000"
|
|
||||||
:interface "SCSI"
|
|
||||||
:comment "OK"
|
|
||||||
:model "Gemini D-16"
|
|
||||||
:interface "SCSI"
|
|
||||||
:comment "OK"
|
|
||||||
:model "UMAX VT600"
|
|
||||||
:interface "SCSI"
|
|
||||||
:comment "not tested"
|
|
||||||
:model "Vista-T630"
|
|
||||||
:interface "SCSI"
|
|
||||||
:comment "OK for some firmwareversions, on others only lineart OK"
|
|
||||||
:model "UC 630"
|
:model "UC 630"
|
||||||
:interface "SCSI"
|
:comment "Version 1.6 OK, others only lineart OK"
|
||||||
:comment "Version 1.6(?) or 2.8(?) OK, others only lineart OK"
|
|
||||||
:model "UG 630"
|
:model "UG 630"
|
||||||
:interface "SCSI"
|
|
||||||
:comment "OK"
|
:comment "OK"
|
||||||
:model "UG 80"
|
:model "UG 80"
|
||||||
:interface "SCSI"
|
|
||||||
:comment "OK"
|
:comment "OK"
|
||||||
:model "UC 840"
|
:model "UC 840"
|
||||||
:interface "SCSI"
|
|
||||||
:comment "Version 1.6 OK, others only lineart OK"
|
:comment "Version 1.6 OK, others only lineart OK"
|
||||||
:model "UC 1200S"
|
:model "UC 1200S"
|
||||||
:interface "SCSI"
|
:comment "does not work (firmware version ?)"
|
||||||
:comment "unknown - please try"
|
|
||||||
:model "UC 1200SE"
|
:model "UC 1200SE"
|
||||||
:interface "SCSI"
|
:comment "?"
|
||||||
:comment "unknown - please try"
|
|
||||||
:model "UC 1260"
|
:model "UC 1260"
|
||||||
:interface "SCSI"
|
|
||||||
:comment "Version 1.6 OK, others unknown"
|
:comment "Version 1.6 OK, others unknown"
|
||||||
|
:model "Mirage"
|
||||||
|
:comment "Not tested"
|
||||||
|
:model "Mirage II"
|
||||||
|
:comment "Not tested"
|
||||||
|
:model "Mirage IIse"
|
||||||
|
:comment "Not tested"
|
||||||
|
:model "Vista-T630"
|
||||||
|
:comment "OK for some firmwareversions, on others only lineart OK"
|
||||||
|
:model "PSD"
|
||||||
|
:comment "OK"
|
||||||
|
:model "PowerLook"
|
||||||
|
:comment "Not tested"
|
||||||
|
:model "PL-II"
|
||||||
|
:comment "only works with some scanners! (unknown why)"
|
||||||
|
:model "PowerLook III"
|
||||||
|
:comment "Not tested"
|
||||||
|
:model "PowerLook 2000"
|
||||||
|
:comment "Not tested"
|
||||||
|
:model "PowerLook 3000"
|
||||||
|
:comment "Not tested"
|
||||||
|
:model "Gemini D-16"
|
||||||
|
:comment "OK"
|
||||||
|
|
||||||
:mfg "Linotype Hell" ; another manufacturer...
|
:mfg "Linotype Hell" ; another manufacturer...
|
||||||
:url "http://www.heidelberg-cps.com/"
|
|
||||||
:model "Jade"
|
:model "Jade"
|
||||||
:interface "SCSI"
|
|
||||||
:comment "OK, SCSI-ID=LinoHell Office"
|
:comment "OK, SCSI-ID=LinoHell Office"
|
||||||
:model "Jade"
|
|
||||||
:interface "SCSI"
|
|
||||||
:comment "OK, SCSI-ID=LinoHell JADE"
|
|
||||||
:model "Jade2"
|
:model "Jade2"
|
||||||
:interface "SCSI"
|
|
||||||
:comment "OK, SCSI-ID=LinoHell Office2"
|
:comment "OK, SCSI-ID=LinoHell Office2"
|
||||||
:model "Saphir"
|
:model "Saphir"
|
||||||
:interface "SCSI"
|
|
||||||
:comment "Not tested"
|
:comment "Not tested"
|
||||||
:model "Saphir2"
|
:model "Saphir2"
|
||||||
:interface "SCSI"
|
|
||||||
:comment "OK, SCSI-ID=LinoHell SAPHIR2"
|
:comment "OK, SCSI-ID=LinoHell SAPHIR2"
|
||||||
:model "Saphir Ultra"
|
:model "Saphir Ultra"
|
||||||
:interface "SCSI"
|
|
||||||
:comment "Not tested"
|
:comment "Not tested"
|
||||||
:model "Saphir Ultra II"
|
:model "Saphir Ultra II"
|
||||||
:interface "SCSI"
|
|
||||||
:comment "Not tested"
|
:comment "Not tested"
|
||||||
:model "Saphir HiRes"
|
:model "Saphir HiRes"
|
||||||
:interface "SCSI"
|
|
||||||
:comment "Not tested"
|
:comment "Not tested"
|
||||||
:model "Opal"
|
:model "Opal"
|
||||||
:interface "SCSI"
|
|
||||||
:comment "Not tested"
|
:comment "Not tested"
|
||||||
:model "Opal Ultra"
|
:model "Opal Ultra"
|
||||||
:interface "SCSI"
|
|
||||||
:comment "Not tested"
|
:comment "Not tested"
|
||||||
:model "Linoscan 1400"
|
|
||||||
:interface "SCSI"
|
|
||||||
:comment "OK, SCSI-ID=HDM LS4H1S"
|
|
||||||
|
|
||||||
:mfg "Vobis/Highscreen"
|
:mfg "Vobis/Highscreen"
|
||||||
:url "http://www.vobis.de/"
|
|
||||||
:model "Scanboostar Premium"
|
:model "Scanboostar Premium"
|
||||||
:interface "SCSI"
|
|
||||||
:comment "OK, SCSI-ID=LinoHell Office2"
|
:comment "OK, SCSI-ID=LinoHell Office2"
|
||||||
|
|
||||||
:mfg "EDGE" ; another manufacturer...
|
|
||||||
; :url "http://???/"
|
|
||||||
:model "KTX-9600US"
|
|
||||||
:interface "SCSI"
|
|
||||||
:comment "no feedback"
|
|
||||||
|
|
||||||
:mfg "Epson" ; another manufacturer...
|
|
||||||
:url "http://www.epson.com/"
|
|
||||||
:model "Perfection 600"
|
|
||||||
:interface "SCSI"
|
|
||||||
:comment "OK, SCSI-ID=EPSON Perfection600"
|
|
||||||
|
|
||||||
:mfg "Escom" ; another manufacturer...
|
:mfg "Escom" ; another manufacturer...
|
||||||
:model "Image Scanner 256"
|
:model "Image Scanner 256"
|
||||||
:interface "SCSI"
|
|
||||||
:comment "OK, SCSI-ID=UMAX UG 80"
|
:comment "OK, SCSI-ID=UMAX UG 80"
|
||||||
|
|
||||||
:mfg "Escort" ; another manufacturer...
|
|
||||||
:model "Galleria 600"
|
|
||||||
:interface "SCSI"
|
|
||||||
:comment "untested, SCSI-ID=ESCORT Galleria 600S"
|
|
||||||
|
|
||||||
:mfg "Genius" ; another manufacturer...
|
|
||||||
:url "http://www.genius.kye.de/"
|
|
||||||
:model "ColorPage-HR5 (Pro)"
|
|
||||||
:interface "SCSI"
|
|
||||||
:comment "OK, SCSI-ID=KYE ColorPage-HR5"
|
|
||||||
|
|
||||||
:mfg "Nikon" ; another manufacturer...
|
:mfg "Nikon" ; another manufacturer...
|
||||||
:url "http://www.nikon.com/"
|
|
||||||
:model "AX-210"
|
:model "AX-210"
|
||||||
:interface "SCSI"
|
|
||||||
:comment "OK"
|
:comment "OK"
|
||||||
|
|
||||||
|
|
||||||
; :comment and :url specifiers are optional after :mfg, :model, :desc,
|
; :comment and :url specifiers are optional after :mfg, :model, :desc,
|
||||||
; and at the top-level.
|
; and at the top-level.
|
||||||
|
|
Plik diff jest za duży
Load Diff
303
configure.in
303
configure.in
|
@ -7,27 +7,20 @@ AC_ARG_PROGRAM
|
||||||
# version code:
|
# version code:
|
||||||
V_MAJOR=1
|
V_MAJOR=1
|
||||||
V_MINOR=0
|
V_MINOR=0
|
||||||
V_REV=6
|
V_REV=1
|
||||||
|
|
||||||
PACKAGE=sane-backends
|
PACKAGE=sane
|
||||||
VERSION=${V_MAJOR}.${V_MINOR}.${V_REV}
|
VERSION=${V_MAJOR}.${V_MINOR}.${V_REV}
|
||||||
PACKAGE_VERSION="$PACKAGE-$VERSION"
|
PACKAGE_VERSION="$PACKAGE-$VERSION"
|
||||||
AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE",
|
AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE")
|
||||||
[Define to the name of the distribution.])
|
AC_DEFINE_UNQUOTED(VERSION, "$VERSION")
|
||||||
AC_DEFINE_UNQUOTED(VERSION, "$VERSION",
|
AC_DEFINE_UNQUOTED(PACKAGE_VERSION, "$PACKAGE_VERSION")
|
||||||
[Define to the version of the distribution.])
|
|
||||||
AC_DEFINE_UNQUOTED(PACKAGE_VERSION, "$PACKAGE_VERSION",
|
|
||||||
[The concatenation of the strings PACKAGE, "-", and VERSION.])
|
|
||||||
AC_DEFINE_UNQUOTED(SANE_DLL_V_MAJOR, $V_MAJOR, [SANE DLL major number])
|
|
||||||
AC_DEFINE_UNQUOTED(SANE_DLL_V_MINOR, $V_MINOR, [SANE DLL minor number])
|
|
||||||
AC_DEFINE_UNQUOTED(SANE_DLL_V_BUILD, $V_REV, [SANE DLL revision number])
|
|
||||||
AC_SUBST(PACKAGE)
|
AC_SUBST(PACKAGE)
|
||||||
AC_SUBST(VERSION)
|
AC_SUBST(VERSION)
|
||||||
AC_SUBST(PACKAGE_VERSION)
|
AC_SUBST(PACKAGE_VERSION)
|
||||||
|
|
||||||
dnl Checks for programs.
|
dnl Checks for programs.
|
||||||
AC_PROG_CC
|
AC_PROG_CC
|
||||||
AC_PROG_LD
|
|
||||||
AC_PROG_INSTALL
|
AC_PROG_INSTALL
|
||||||
AC_PROG_MAKE_SET
|
AC_PROG_MAKE_SET
|
||||||
AC_PROG_CPP
|
AC_PROG_CPP
|
||||||
|
@ -35,76 +28,21 @@ AC_PROG_GCC_TRADITIONAL
|
||||||
AC_AIX
|
AC_AIX
|
||||||
AC_MINIX
|
AC_MINIX
|
||||||
AC_ISC_POSIX
|
AC_ISC_POSIX
|
||||||
AM_PROG_CC_STDC
|
|
||||||
|
|
||||||
INCLUDES="${INCLUDES} -I/usr/local/include"
|
INCLUDES="${INCLUDES} -I/usr/local/include"
|
||||||
CPPFLAGS="${CPPFLAGS} -D_GNU_SOURCE"
|
CPPFLAGS="${CPPFLAGS} -D_GNU_SOURCE"
|
||||||
|
|
||||||
if test "${ac_cv_prog_gcc}" = "yes"; then
|
if test "${ac_cv_prog_gcc}" = "yes"; then
|
||||||
NORMAL_CFLAGS="\
|
CFLAGS="${CFLAGS} -Wall"
|
||||||
-W \
|
fi
|
||||||
-Wall"
|
|
||||||
WARN_CFLAGS="\
|
|
||||||
-W \
|
|
||||||
-Wall \
|
|
||||||
-Wcast-align \
|
|
||||||
-Wcast-qual \
|
|
||||||
-Wmissing-declarations \
|
|
||||||
-Wmissing-prototypes \
|
|
||||||
-Wpointer-arith \
|
|
||||||
-Wreturn-type \
|
|
||||||
-Wstrict-prototypes \
|
|
||||||
-pedantic"
|
|
||||||
|
|
||||||
dnl OS/2 and others don't include some headers with -ansi enabled
|
|
||||||
ANSI_FLAG=-ansi
|
|
||||||
AC_CHECK_HEADER(os2.h,[ANSI_FLAG=],)
|
|
||||||
case "${host_os}" in
|
|
||||||
solaris*)
|
|
||||||
ANSI_FLAG=
|
|
||||||
;;
|
|
||||||
esac
|
|
||||||
WARN_CFLAGS="${WARN_CFLAGS} ${ANSI_FLAG}"
|
|
||||||
|
|
||||||
# Warnings enabled by default (development)
|
|
||||||
AC_ARG_ENABLE(warnings,
|
|
||||||
[ --enable-warnings turn on tons of compiler warnings (GCC only)
|
|
||||||
[default=yes]],
|
|
||||||
[
|
|
||||||
if eval "test x$enable_warnings = xyes"; then
|
|
||||||
for flag in $WARN_CFLAGS; do
|
|
||||||
JAPHAR_GREP_CFLAGS($flag, [ CFLAGS="$CFLAGS $flag" ])
|
|
||||||
done
|
|
||||||
else
|
|
||||||
for flag in $NORMAL_CFLAGS; do
|
|
||||||
JAPHAR_GREP_CFLAGS($flag, [ CFLAGS="$CFLAGS $flag" ])
|
|
||||||
done
|
|
||||||
fi
|
|
||||||
],
|
|
||||||
[if false; then # release (false) or development (true)
|
|
||||||
# Warnings enabled by default (development)
|
|
||||||
for flag in $WARN_CFLAGS; do
|
|
||||||
JAPHAR_GREP_CFLAGS($flag, [ CFLAGS="$CFLAGS $flag" ])
|
|
||||||
done
|
|
||||||
else
|
|
||||||
# Warnings disabled by default (release)
|
|
||||||
for flag in $NORMAL_CFLAGS; do
|
|
||||||
JAPHAR_GREP_CFLAGS($flag, [ CFLAGS="$CFLAGS $flag" ])
|
|
||||||
done
|
|
||||||
fi])
|
|
||||||
fi # ac_cv_prog_gcc
|
|
||||||
echo using CFLAGS=${CFLAGS}
|
|
||||||
|
|
||||||
dnl Checks for header files.
|
dnl Checks for header files.
|
||||||
AC_HEADER_STDC
|
AC_HEADER_STDC
|
||||||
AC_CHECK_HEADERS(fcntl.h unistd.h libc.h sys/dsreq.h sys/select.h \
|
AC_CHECK_HEADERS(fcntl.h unistd.h libintl.h libc.h sys/dsreq.h sys/select.h \
|
||||||
sys/time.h sys/shm.h \
|
sys/time.h jconfig.h \
|
||||||
sys/scanio.h scsi.h sys/scsi.h sys/scsicmd.h sys/scsiio.h \
|
sys/scanio.h scsi.h sys/scsi.h sys/scsicmd.h sys/scsiio.h \
|
||||||
bsd/dev/scsireg.h scsi/sg.h /usr/src/linux/include/scsi/sg.h io/cam/cam.h \
|
bsd/dev/scsireg.h scsi/sg.h /usr/src/linux/include/scsi/sg.h io/cam/cam.h \
|
||||||
camlib.h os2.h sys/socket.h sys/io.h asm/io.h gscdds.h sys/hw.h \
|
camlib.h os2.h sys/socket.h sys/io.h asm/io.h gscdds.h sys/hw.h \
|
||||||
sys/types.h sys/scsi/scsi.h sys/scsi/sgdefs.h sys/scsi/targets/scgio.h \
|
sys/types.h sys/scsi/sgdefs.h sys/scsi/targets/scgio.h apollo/scsi.h)
|
||||||
apollo/scsi.h sys/sdi_comm.h sys/passthrudef.h linux/ppdev.h usb.h \
|
|
||||||
sys/bitypes.h sys/sem.h)
|
|
||||||
|
|
||||||
dnl Checks for typedefs, structures, and compiler characteristics.
|
dnl Checks for typedefs, structures, and compiler characteristics.
|
||||||
AC_C_CONST
|
AC_C_CONST
|
||||||
|
@ -113,13 +51,10 @@ AC_TYPE_SIGNAL
|
||||||
AC_TYPE_SIZE_T
|
AC_TYPE_SIZE_T
|
||||||
AC_TYPE_PID_T
|
AC_TYPE_PID_T
|
||||||
AC_CHECK_TYPE(ssize_t, long)
|
AC_CHECK_TYPE(ssize_t, long)
|
||||||
SANE_CHECK_U_TYPES
|
AC_CHECK_TYPE(u_char, unsigned char)
|
||||||
|
AC_CHECK_TYPE(u_int, unsigned int)
|
||||||
|
AC_CHECK_TYPE(u_long, unsigned long)
|
||||||
|
|
||||||
AC_MSG_CHECKING([for struct flock in fcntl.h])
|
|
||||||
AC_EGREP_HEADER([struct flock], fcntl.h, [AC_MSG_RESULT(yes) ;
|
|
||||||
AC_DEFINE(HAVE_STRUCT_FLOCK, 1,
|
|
||||||
[Define if struct flock is available.])], AC_MSG_RESULT(no))
|
|
||||||
|
|
||||||
if test "$ac_cv_header_sys_scsiio_h" = "yes" \
|
if test "$ac_cv_header_sys_scsiio_h" = "yes" \
|
||||||
-a "$ac_cv_header_scsi_h" = "yes";
|
-a "$ac_cv_header_scsi_h" = "yes";
|
||||||
then
|
then
|
||||||
|
@ -127,50 +62,16 @@ then
|
||||||
#include <sys/scsiio.h>
|
#include <sys/scsiio.h>
|
||||||
#include <scsi.h>
|
#include <scsi.h>
|
||||||
],[scsireq_t req],,
|
],[scsireq_t req],,
|
||||||
AC_DEFINE(scsireq_t, struct scsireq_t,
|
AC_DEFINE(scsireq_t, struct scsireq_t))
|
||||||
[Define scsireq_t as \`struct scsireq\' if necessary.]))
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
AC_MSG_CHECKING([for socklen_t in <sys/socket.h>])
|
dnl Checks for libraries.
|
||||||
AC_TRY_COMPILE([
|
|
||||||
#include <sys/socket.h>
|
|
||||||
],[socklen_t len],AC_MSG_RESULT(yes),
|
|
||||||
[AC_MSG_RESULT(no); AC_DEFINE(socklen_t,int,
|
|
||||||
[Define socklen_t as \`int\' if necessary.])])
|
|
||||||
|
|
||||||
SANE_V4L_VERSION
|
|
||||||
|
|
||||||
dnl Checks for dll libraries: dl
|
|
||||||
if test "${enable_dynamic}" != "no"; then
|
|
||||||
AC_CHECK_HEADERS(dlfcn.h,
|
|
||||||
[AC_CHECK_LIB(dl,dlopen, DL_LIB=-ldl)
|
|
||||||
saved_LIBS="${LIBS}"
|
|
||||||
LIBS="${LIBS} ${DL_LIB}"
|
|
||||||
AC_CHECK_FUNCS(dlopen, enable_dynamic=yes,)
|
|
||||||
LIBS="${saved_LIBS}"
|
|
||||||
],)
|
|
||||||
|
|
||||||
# HP/UX DLL handling
|
|
||||||
AC_CHECK_HEADERS(dl.h,
|
|
||||||
[AC_CHECK_LIB(dld,shl_load, DL_LIB=-ldld)
|
|
||||||
saved_LIBS="${LIBS}"
|
|
||||||
LIBS="${LIBS} ${DL_LIB}"
|
|
||||||
AC_CHECK_FUNCS(shl_load, enable_dynamic=yes,)
|
|
||||||
LIBS="${saved_LIBS}"
|
|
||||||
],)
|
|
||||||
fi
|
|
||||||
AC_SUBST(DL_LIB)
|
|
||||||
|
|
||||||
dnl Checks for Backend libraries.
|
|
||||||
AC_CHECK_LIB(m,sqrt)
|
|
||||||
AC_CHECK_LIB(scsi, scsireq_enter) # FreeBSD needs this
|
AC_CHECK_LIB(scsi, scsireq_enter) # FreeBSD needs this
|
||||||
AC_CHECK_LIB(cam, cam_open_device) # FreeBSD 3+ needs this
|
AC_CHECK_LIB(m,sqrt)
|
||||||
AC_CHECK_LIB(syslog, syslog) # OS/2 needs this
|
AC_CHECK_LIB(intl,gettext)
|
||||||
AC_CHECK_LIB(usb, usb_open)
|
AC_CHECK_LIB(syslog,syslog) # OS/2 needs this
|
||||||
|
AC_CHECK_LIB(jpeg,jpeg_start_decompress)
|
||||||
SANE_CHECK_JPEG
|
|
||||||
|
|
||||||
SANE_CHECK_GPHOTO2
|
|
||||||
|
|
||||||
dnl IRIX sometimes has SYSVR3/4 network DSOs, but we do not need or want
|
dnl IRIX sometimes has SYSVR3/4 network DSOs, but we do not need or want
|
||||||
dnl to use them!
|
dnl to use them!
|
||||||
|
@ -179,60 +80,80 @@ if test "`uname`" != "IRIX" -a "`uname`" != "IRIX64"; then
|
||||||
AC_CHECK_LIB(socket,socket)
|
AC_CHECK_LIB(socket,socket)
|
||||||
fi
|
fi
|
||||||
|
|
||||||
dnl check for PTAL library (used in hp backend)
|
|
||||||
SANE_CHECK_PTAL
|
|
||||||
|
|
||||||
dnl look for /dev/urandom
|
|
||||||
if test -c /dev/urandom ; then
|
|
||||||
AC_DEFINE(HAVE_DEV_URANDOM, 1, [Is /dev/urandom available?])
|
|
||||||
fi
|
|
||||||
|
|
||||||
dnl Checks for library functions.
|
dnl Checks for library functions.
|
||||||
AC_FUNC_ALLOCA
|
AM_FUNC_ALLOCA
|
||||||
AC_FUNC_MMAP
|
AC_FUNC_MMAP
|
||||||
AC_CHECK_FUNCS(atexit ioperm mkdir scsireq_enter sigprocmask \
|
AC_CHECK_FUNCS(atexit ioperm mkdir scsireq_enter sigprocmask \
|
||||||
strdup strndup strftime strstr strsep strtod snprintf \
|
strdup strndup strftime strstr strsep strtod snprintf \
|
||||||
cfmakeraw tcsendbreak usleep strcasecmp strncasecmp _portaccess \
|
cfmakeraw tcsendbreak usleep strcasecmp strncasecmp _portaccess)
|
||||||
getenv isfdtype vsyslog)
|
|
||||||
|
|
||||||
SANE_LINKER_RPATH
|
|
||||||
|
|
||||||
dnl initialize libtool
|
dnl initialize libtool
|
||||||
AC_LIBTOOL_WIN32_DLL
|
|
||||||
AM_PROG_LIBTOOL
|
AM_PROG_LIBTOOL
|
||||||
|
|
||||||
|
dnl Checks for libraries.
|
||||||
|
|
||||||
|
#### Choose a window system.
|
||||||
|
|
||||||
|
AC_PATH_X
|
||||||
|
if test "$no_x" = yes; then
|
||||||
|
window_system=none
|
||||||
|
else
|
||||||
|
window_system=x11
|
||||||
|
fi
|
||||||
|
|
||||||
|
if test "${enable_dynamic}" != "no"; then
|
||||||
|
AC_CHECK_HEADERS(dlfcn.h,
|
||||||
|
[AC_CHECK_LIB(dl,dlopen)
|
||||||
|
AC_CHECK_FUNCS(dlopen, enable_dynamic=yes,)],)
|
||||||
|
|
||||||
|
# HP/UX DLL handling
|
||||||
|
AC_CHECK_HEADERS(dl.h,
|
||||||
|
[AC_CHECK_LIB(dld,shl_load)
|
||||||
|
AC_CHECK_FUNCS(shl_load, enable_dynamic=yes,)],)
|
||||||
|
fi
|
||||||
|
|
||||||
|
AM_PATH_GTK(0.99.13, HAVE_GTK=yes, )
|
||||||
|
|
||||||
|
# Change CFLAGS temporarily so that C_SWITCH_X_SITE gets used
|
||||||
|
# for the tests that follow. We set it back to REAL_CFLAGS later on.
|
||||||
|
|
||||||
|
if test "${HAVE_GTK}" = "yes"; then
|
||||||
|
XSCAN="xscanimage xcam"
|
||||||
|
|
||||||
|
# According to Owen Taylor, GTK_CFLAGS is _guaranteed_ to contain
|
||||||
|
# -D and -I flags only, i.e., it really is GTK_CPPFLAGS...
|
||||||
|
saved_CPPFLAGS="${CPPFLAGS}"
|
||||||
|
saved_LIBS="${LIBS}"
|
||||||
|
CPPFLAGS="${CPPFLAGS} ${GTK_CFLAGS}"
|
||||||
|
LIBS="${LIBS} ${GTK_LIBS}"
|
||||||
|
|
||||||
|
AC_CHECK_FUNCS(gtk_tooltips_set_tips gtk_events_pending)
|
||||||
|
if test "${ac_cv_func_gtk_events_pending}" = "no"; then
|
||||||
|
saved_CPPFLAGS="${saved_CPPFLAGS} -Dgtk_events_pending=gdk_events_pending"
|
||||||
|
fi
|
||||||
|
|
||||||
|
AC_CHECK_HEADERS(libgimp/gimp.h,GIMP_LIBS="-lgimp")
|
||||||
|
|
||||||
|
CPPFLAGS="${saved_CPPFLAGS}"
|
||||||
|
LIBS="${saved_LIBS}"
|
||||||
|
fi
|
||||||
AC_SUBST(INCLUDES)
|
AC_SUBST(INCLUDES)
|
||||||
|
AC_SUBST(XSCAN)
|
||||||
|
AC_SUBST(GTK_CFLAGS)
|
||||||
|
AC_SUBST(GTK_LIBS)
|
||||||
|
AC_SUBST(GIMP_LIBS)
|
||||||
CPPFLAGS="${CPPFLAGS} -DPATH_SANE_CONFIG_DIR=\$(configdir) \
|
CPPFLAGS="${CPPFLAGS} -DPATH_SANE_CONFIG_DIR=\$(configdir) \
|
||||||
-DPATH_SANE_DATA_DIR=\$(datadir) \
|
-DPATH_SANE_DATA_DIR=\$(datadir) \
|
||||||
-DV_MAJOR=${V_MAJOR} -DV_MINOR=${V_MINOR}"
|
-DV_MAJOR=${V_MAJOR} -DV_MINOR=${V_MINOR}"
|
||||||
|
|
||||||
if test "${sane_cv_use_libjpeg}" != "yes"; then
|
if test "${ac_cv_header_jconfig_h}" = "no"; then
|
||||||
echo "disabling DC210/DC240 backends (failed to find JPEG library)"
|
echo "disabling DC210 backend (failed to find JPEG library)"
|
||||||
DC210=
|
DC210=
|
||||||
DC240=
|
|
||||||
DJPEG=
|
|
||||||
else
|
else
|
||||||
echo "enabling DC210/DC240 backends"
|
echo "enabling DC210 backend"
|
||||||
DC210=dc210
|
DC210=dc210
|
||||||
DC240=dc240
|
|
||||||
DJPEG=djpeg
|
|
||||||
fi
|
fi
|
||||||
AC_SUBST(DC210)
|
AC_SUBST(DC210)
|
||||||
AC_SUBST(DC240)
|
|
||||||
AC_SUBST(DJPEG)
|
|
||||||
|
|
||||||
|
|
||||||
if test "${HAVE_GPHOTO2}" != "gphoto2" \
|
|
||||||
-o "${sane_cv_use_libjpeg}" != "yes"; then
|
|
||||||
echo "disabling GPHOTO2 backend (failed to find gphoto2 or JPEG lib)"
|
|
||||||
GPHOTO2=
|
|
||||||
else
|
|
||||||
echo "enabling GPHOTO2 backend"
|
|
||||||
GPHOTO2=gphoto2
|
|
||||||
fi
|
|
||||||
AC_SUBST(GPHOTO2)
|
|
||||||
|
|
||||||
if test "${ac_cv_header_sys_scanio_h}" = "no"; then
|
if test "${ac_cv_header_sys_scanio_h}" = "no"; then
|
||||||
echo "disabling PINT backend"
|
echo "disabling PINT backend"
|
||||||
PINT=
|
PINT=
|
||||||
|
@ -251,15 +172,6 @@ else
|
||||||
QCAM=qcam
|
QCAM=qcam
|
||||||
fi
|
fi
|
||||||
AC_SUBST(QCAM)
|
AC_SUBST(QCAM)
|
||||||
if test "${sane_v4l_version}" = "v4l"
|
|
||||||
then
|
|
||||||
echo "enabling Video4Linux backend"
|
|
||||||
V4L=v4l
|
|
||||||
else
|
|
||||||
echo "disabling Video4Linux backend"
|
|
||||||
V4L=
|
|
||||||
fi
|
|
||||||
AC_SUBST(V4L)
|
|
||||||
if test "${ac_cv_header_sys_socket_h}" = "no"; then
|
if test "${ac_cv_header_sys_socket_h}" = "no"; then
|
||||||
echo "disabling NET backend"
|
echo "disabling NET backend"
|
||||||
NET=
|
NET=
|
||||||
|
@ -271,24 +183,6 @@ else
|
||||||
fi
|
fi
|
||||||
AC_SUBST(NET)
|
AC_SUBST(NET)
|
||||||
AC_SUBST(SANED)
|
AC_SUBST(SANED)
|
||||||
if test "${ac_cv_header_usb_h}" = "no" \
|
|
||||||
-o "${ac_cv_lib_usb_usb_open}" = "no"; then
|
|
||||||
echo "disabling SM3600 backend"
|
|
||||||
SM3600=
|
|
||||||
else
|
|
||||||
echo "enabling SM3600 backend"
|
|
||||||
SM3600=sm3600
|
|
||||||
fi
|
|
||||||
AC_SUBST(SM3600)
|
|
||||||
if test "${ac_cv_header_sys_sem_h}" = "no" ; then
|
|
||||||
echo "disabling SnapScan backend"
|
|
||||||
SNAPSCAN=
|
|
||||||
else
|
|
||||||
echo "enabling SnapScan backend"
|
|
||||||
SNAPSCAN=snapscan
|
|
||||||
fi
|
|
||||||
AC_SUBST(SNAPSCAN)
|
|
||||||
|
|
||||||
if test "${enable_shared}" = "no"; then
|
if test "${enable_shared}" = "no"; then
|
||||||
enable_preload=yes
|
enable_preload=yes
|
||||||
fi
|
fi
|
||||||
|
@ -298,34 +192,6 @@ if test "${enable_dynamic}" != yes || test "${enable_preload}" = "yes"; then
|
||||||
else
|
else
|
||||||
DLL_PRELOAD=""
|
DLL_PRELOAD=""
|
||||||
fi
|
fi
|
||||||
|
|
||||||
AC_ARG_ENABLE(pnm-backend,
|
|
||||||
[ --enable-pnm-backend enable the pnm backend for testing frontends. Warning:
|
|
||||||
This will be a security risk if used together with saned.
|
|
||||||
See PROBLEMS file for details. [default=no]],
|
|
||||||
[PNM="pnm"], [PNM=""])
|
|
||||||
AC_SUBST(PNM)
|
|
||||||
|
|
||||||
AC_ARG_ENABLE(scsibuffersize,
|
|
||||||
[ --enable-scsibuffersize=N specify the default size (in bytes) of the buffer
|
|
||||||
for SCSI commands [default=131072]],
|
|
||||||
[set_scsibuffersize="$enableval"], [set_scsibuffersize=131072])
|
|
||||||
AC_DEFINE_UNQUOTED(SCSIBUFFERSIZE, $set_scsibuffersize,
|
|
||||||
[SCSI command buffer size])
|
|
||||||
echo "scsi buffersize: $set_scsibuffersize"
|
|
||||||
|
|
||||||
AC_ARG_ENABLE(directio,
|
|
||||||
[ --enable-directio enable direct IO (Linux only; can lead to crashes
|
|
||||||
with backends using shared memory) [default=no]],
|
|
||||||
[
|
|
||||||
if eval "test x$enable_directio = xyes"; then
|
|
||||||
CFLAGS="$CFLAGS -DENABLE_DIRECTIO"
|
|
||||||
fi
|
|
||||||
])
|
|
||||||
|
|
||||||
AC_PATH_PROG(SANE_CONFIG_PATH, sane-config, no)
|
|
||||||
AC_CHECK_LIB(sane, sane_init, LIBSANE_EXISTS="yes")
|
|
||||||
|
|
||||||
AC_SUBST(V_MAJOR)
|
AC_SUBST(V_MAJOR)
|
||||||
AC_SUBST(V_MINOR)
|
AC_SUBST(V_MINOR)
|
||||||
AC_SUBST(V_REV)
|
AC_SUBST(V_REV)
|
||||||
|
@ -333,26 +199,7 @@ AC_SUBST(DLL_PRELOAD)
|
||||||
|
|
||||||
AC_OUTPUT([Makefile lib/Makefile sanei/Makefile frontend/Makefile
|
AC_OUTPUT([Makefile lib/Makefile sanei/Makefile frontend/Makefile
|
||||||
japi/Makefile backend/Makefile include/Makefile doc/Makefile
|
japi/Makefile backend/Makefile include/Makefile doc/Makefile
|
||||||
testsuite/Makefile
|
tools/Makefile],)
|
||||||
tools/Makefile tools/sane-config],)
|
|
||||||
|
|
||||||
if test "$SANE_CONFIG_PATH" != "no" ; then
|
|
||||||
SANE_INSTALLED_VERSION=`$SANE_CONFIG_PATH --version`
|
|
||||||
SANE_INSTALLED_PREFIX=`$SANE_CONFIG_PATH --prefix`
|
|
||||||
if test "$SANE_INSTALLED_PREFIX" != "$prefix" ; then
|
|
||||||
echo "*** WARNING: SANE is already installed (version $SANE_INSTALLED_VERSION). The old"
|
|
||||||
echo "*** installation is at $SANE_INSTALLED_PREFIX while SANE will now be installed"
|
|
||||||
echo "*** at $prefix. It is recommended to uninstall the old SANE version"
|
|
||||||
echo "*** before installing the new one to avoid problems."
|
|
||||||
fi
|
|
||||||
else
|
|
||||||
if test "$LIBSANE_EXISTS" = "yes" ; then
|
|
||||||
echo "*** Warning: An old version of SANE was detected but the sane-config program"
|
|
||||||
echo "*** couldn't be found. If you encounter any problems with SANE remove the old"
|
|
||||||
echo "*** SANE files and reinstall this version."
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
|
|
||||||
|
|
||||||
echo "****************************************************************"
|
echo "****************************************************************"
|
||||||
echo "* Please be sure to read file PROBLEMS in this directory *"
|
echo "* Please be sure to read file PROBLEMS in this directory *"
|
||||||
|
|
|
@ -1,7 +1,5 @@
|
||||||
. .IX sane-microtek2
|
.TH sane-microtek2 5 "06 Nov 1998"
|
||||||
." Process this file with
|
.IX sane-microtek2
|
||||||
." man -l sane-microtek2.man
|
|
||||||
.TH sane-microtek2 5 "27 Oct 2001"
|
|
||||||
.SH NAME
|
.SH NAME
|
||||||
sane-microtek2 - SANE backend for Microtek scanners with SCSI-2 command set
|
sane-microtek2 - SANE backend for Microtek scanners with SCSI-2 command set
|
||||||
.SH DESCRIPTION
|
.SH DESCRIPTION
|
||||||
|
@ -9,143 +7,56 @@ The
|
||||||
.B sane-microtek2
|
.B sane-microtek2
|
||||||
library implements a SANE (Scanner Access Now Easy) backend that
|
library implements a SANE (Scanner Access Now Easy) backend that
|
||||||
provides access to some Microtek scanners with a SCSI-2 command set.
|
provides access to some Microtek scanners with a SCSI-2 command set.
|
||||||
This backend can be considered alpha to beta. Some scanner models are reported
|
This backend should be considered alpha.
|
||||||
to work well, others not. New development versions of this backend can be
|
.PP
|
||||||
obtained from
|
There exists a different backend for Microtek scanners with SCSI-1
|
||||||
.B http://home.t-online.de/home/karsten.festag
|
command set. Refer to sane-microtek(5) for details.
|
||||||
.PP
|
.PP
|
||||||
There exists a different backend for Microtek scanners with SCSI-1 command
|
At present, the following
|
||||||
set.
|
scanners are known positively to work with this backend:
|
||||||
Refer to sane-microtek(5) for details.
|
|
||||||
.PP
|
.PP
|
||||||
And there is work in progress for the ScanMaker 3600.
|
.RS
|
||||||
See
|
Vendor Product id: Remark:
|
||||||
.B http://sourceforge.net/projects/sm3600
|
.br
|
||||||
|
-------- -------------- -----------
|
||||||
|
.br
|
||||||
|
Microtek E3plus all modes ok
|
||||||
|
.br
|
||||||
|
Microtek X6 all modes ok
|
||||||
|
.br
|
||||||
|
Microtek ScanMaker 330 all modes ok
|
||||||
|
.br
|
||||||
|
Microtek ScanMaker 630 all modes ok
|
||||||
|
.br
|
||||||
|
Microtek ScanMaker 636 all modes ok
|
||||||
|
.br
|
||||||
|
Microtek Phantom 636 all modes ok
|
||||||
|
.br
|
||||||
|
Vobis HighScan all modes ok
|
||||||
|
.RE
|
||||||
.PP
|
.PP
|
||||||
At present, the following scanners are known positively to work with this
|
If you own a Microtek scanner with SCSI-2 interface other than the ones
|
||||||
backend:
|
listed above, it may or may not work with SANE!
|
||||||
.PP
|
|
||||||
Vendor Product id: Remark
|
|
||||||
.br
|
|
||||||
-------- -------------- -------------
|
|
||||||
.br
|
|
||||||
Microtek E3+ Parport and SCSI
|
|
||||||
.br
|
|
||||||
Microtek X6 SCSI
|
|
||||||
.br
|
|
||||||
Microtek X6EL SCSI
|
|
||||||
.br
|
|
||||||
Microtek X6USB USB
|
|
||||||
.br
|
|
||||||
Microtek ScanMaker V300 Parport and SCSI
|
|
||||||
.br
|
|
||||||
Microtek ScanMaker V310 Parport and SCSI
|
|
||||||
.br
|
|
||||||
Microtek ScanMaker V600 Parport and SCSI
|
|
||||||
.br
|
|
||||||
Microtek ScanMaker 330 SCSI
|
|
||||||
.br
|
|
||||||
Microtek ScanMaker 630 SCSI
|
|
||||||
.br
|
|
||||||
Microtek ScanMaker 636 SCSI
|
|
||||||
.br
|
|
||||||
Microtek ScanMaker 9600XL SCSI; only flatbed mode?
|
|
||||||
.br
|
|
||||||
Microtek Phantom 330CX Parport
|
|
||||||
.br
|
|
||||||
Microtek SlimScan C3 Parport
|
|
||||||
.br
|
|
||||||
Microtek SlimScan C6 USB
|
|
||||||
.br
|
|
||||||
Microtek Phantom 636 SCSI
|
|
||||||
.br
|
|
||||||
Microtek Phantom 636CX Parport
|
|
||||||
.br
|
|
||||||
Microtek V6USL SCSI (and USB ???)
|
|
||||||
.br
|
|
||||||
Microtek V6UPL USB; not stable
|
|
||||||
.br
|
|
||||||
Vobis HighScan SCSI (E3+ based models)
|
|
||||||
.br
|
|
||||||
Scanport SQ300 Parport?
|
|
||||||
.br
|
|
||||||
Scanport SQ4836 SCSI
|
|
||||||
.br
|
|
||||||
Scanpaq SQ2030 Parport
|
|
||||||
.PP
|
|
||||||
Additional information can be found at
|
|
||||||
.B http://www.mostang.com/sane/ .
|
|
||||||
.PP
|
|
||||||
If you own a Microtek scanner other than the ones listed above,
|
|
||||||
it may or may not work with SANE! Because equal scanners are sold under
|
|
||||||
different names in different countries your model may be equivalent to one of
|
|
||||||
the above.
|
|
||||||
.PP
|
|
||||||
The parport scanners work with the ppscsi + onscsi kernel modules. See
|
|
||||||
.B http://www.torque.net/parport/ppscsi.html
|
|
||||||
.PP
|
|
||||||
The USB scanners work with the microtek kernel module. You may have to add the
|
|
||||||
vendor and model codes to microtek.c if they aren't yet listed there.
|
|
||||||
.PP
|
|
||||||
Both parport and USB scanners need the generic SCSI support, so check if you
|
|
||||||
have loaded the scsi_mod and sg modules!
|
|
||||||
.PP
|
|
||||||
If you try your scanner for the first time keep an eye on it. If it gets
|
|
||||||
commands that it doesn't understand the scanhead may go beyond the scan area.
|
|
||||||
The scanner then makes strange noises. In this case immedieately switch off
|
|
||||||
the scanner or disconnect its power cable to prevent damages!
|
|
||||||
.PP
|
|
||||||
If your scanner is a different one than the models mentioned above and it is
|
|
||||||
working please tell the author about it. It would be nice if you add a logfile
|
|
||||||
to this information (creation of the logfile: see below).
|
|
||||||
.PP
|
|
||||||
If your scanner is not working properly you also should create a logfile and
|
|
||||||
send it to the author. He will use the information to improve the backend and
|
|
||||||
possibly make your scanner work.
|
|
||||||
.PP
|
|
||||||
.br
|
|
||||||
How to create the logfile?
|
|
||||||
.TP
|
|
||||||
- put the line
|
|
||||||
.br
|
|
||||||
"option dump 2" into your
|
|
||||||
.I microtek2.conf
|
|
||||||
file or change the existing "option dump" to "2"
|
|
||||||
.TP
|
|
||||||
- in a terminal (bash) type
|
|
||||||
.br
|
|
||||||
"export SANE_DEBUG_MICROTEK2=30" and then
|
|
||||||
.br
|
|
||||||
"scanimage -l0 -t0 -x100 -y20 2>scan.log >sout.pnm"
|
|
||||||
.br
|
|
||||||
You get two files: scan.log contains the logfile and sout.pnm the scanned
|
|
||||||
image (if there was scanned something). Zip them before sending.
|
|
||||||
|
|
||||||
.SH "FRONTEND OPTIONS"
|
.SH "FRONTEND OPTIONS"
|
||||||
This backend dynamically enables the options for the frontend, that are
|
This backend dynamically enables the options for the frontend,
|
||||||
supported by the scanner in dependence of the scanning-mode and other
|
that are supported by the scanner in dependence of the scanning-mode
|
||||||
options.
|
and other options. Not supported options are disabled.
|
||||||
Not supported options are disabled.
|
|
||||||
.PP
|
.PP
|
||||||
The following options are supported by the Microtek2-driver:
|
The following options are supported by the Microtek2-driver:
|
||||||
.PP
|
.PP
|
||||||
Color, grayscale, halftone and lineart scans.
|
Color, grayscale, halftone and lineart scans.
|
||||||
.PP
|
.PP
|
||||||
Highlight, midtone, shadow, contrast, brightness, exposure time control,
|
Highlight, midtone, shadow, contrast, brightness, exposure time control,
|
||||||
gamma correction, threshold (dependent of the scan mode and the scanner
|
gamma correction, threshold (dependent of the scan mode)
|
||||||
capabilities)
|
|
||||||
.PP
|
.PP
|
||||||
Transparency media adapter, automatic document feeder
|
Transparency media adapter, automatic document feeder
|
||||||
.PP
|
|
||||||
Additional options can be enabled or disabled in the
|
|
||||||
.I microtek2.conf
|
|
||||||
file. See the configuration section of this manpage.
|
|
||||||
|
|
||||||
.SH "DEVICE NAMES"
|
.SH "DEVICE NAMES"
|
||||||
This backend expects device names of the form:
|
This backend expects device names of the form:
|
||||||
.PP
|
.PP
|
||||||
.RS
|
.RS
|
||||||
.I special
|
.IR special
|
||||||
.RE
|
.RE
|
||||||
.PP
|
.PP
|
||||||
Where
|
Where
|
||||||
|
@ -153,99 +64,58 @@ Where
|
||||||
is the UNIX path-name for the special device that corresponds to the
|
is the UNIX path-name for the special device that corresponds to the
|
||||||
scanner. The special device name must be a generic SCSI device or a
|
scanner. The special device name must be a generic SCSI device or a
|
||||||
symlink to such a device. Under Linux, such a device name could be
|
symlink to such a device. Under Linux, such a device name could be
|
||||||
.I /dev/sga
|
.IR /dev/sga
|
||||||
or
|
or
|
||||||
.I /dev/sge
|
.IR /dev/sge ,
|
||||||
for example.
|
for example.
|
||||||
.SH "CONFIGURATION"
|
.SH CONFIGURATION
|
||||||
The configuration file for this backend resides in
|
The configuration file for this backend resides in
|
||||||
.I @CONFIGDIR@/microtek2.conf
|
.IR @CONFIGDIR@/microtek2.conf .
|
||||||
.
|
|
||||||
Its contents is a list of device names that correspond to Microtek
|
Its contents is a list of device names that correspond to Microtek
|
||||||
scanners with SCSI-2 interface. Empty lines and lines starting with
|
scanners with SCSI-2 interface. Empty lines and lines starting with
|
||||||
a hash mark (#) are ignored.
|
a hash mark (#) are ignored.
|
||||||
.PP
|
.PP
|
||||||
The configuration file may also contain options. Global options that are valid
|
The configuration file may also contain options. Currently two options are
|
||||||
for all devices are placed above the device names. Device-specific options
|
supported:
|
||||||
are
|
|
||||||
placed under the device name. Currently the following options are supported:
|
|
||||||
.PP
|
.PP
|
||||||
.RS
|
.RS
|
||||||
option dump <n>
|
option dump <n>
|
||||||
.br
|
.br
|
||||||
option strip-height <n>
|
option strip-height <n>
|
||||||
.br
|
|
||||||
option no-backtrack-option <on/off>
|
|
||||||
.br
|
|
||||||
option lightlid-35 <on/off>
|
|
||||||
.br
|
|
||||||
option toggle-lamp <on/off>
|
|
||||||
.br
|
|
||||||
option lineart-autoadjust <on/off>
|
|
||||||
.br
|
|
||||||
option backend-calibration <on/off>
|
|
||||||
.br
|
|
||||||
option colorbalance-adjust <on/off>
|
|
||||||
.RE
|
.RE
|
||||||
.PP
|
.PP
|
||||||
|
If
|
||||||
.I option dump <n>
|
.I option dump <n>
|
||||||
enables printing of additional information about the SCSI commands that are
|
is enabled additional informations about the SCSI
|
||||||
sent to the scanner to stderr. This option is primarily useful for debugging
|
commands that are sent to the scanner are printed to stderr. This option
|
||||||
purpose. This option has to be a global option and is best placed at the top
|
is primarily useful for debugging purpose.
|
||||||
of the
|
|
||||||
.I microtek2.conf
|
|
||||||
file.
|
|
||||||
.PP
|
.PP
|
||||||
If n=1 the contents of the command blocks
|
If n=1 the contents of the command blocks
|
||||||
and the results for the INQUIRY and READ SCANNER ATTRIBUTES command are
|
and the results for the INQUIRY and READ SCANNER ATTRIBUTES command are
|
||||||
printed to stderr.
|
printed to stderr.
|
||||||
.PP
|
.PP
|
||||||
If n=2 the contents of the command blocks for all other SCSI commands are
|
If n=2 the contents of the command blocks for all other SCSI commands are
|
||||||
printed to stderr, too. If n=3 the contents of the gamma table is
|
printed to stderr, too. If n=3 the contents of the gamma table is
|
||||||
printed, too. If n=4 all scan data is additionally printed to stderr.
|
printed, too. If n=4 all scan data is additionally printed to stderr.
|
||||||
.PP
|
.PP
|
||||||
The default is n=1.
|
The default is n=1.
|
||||||
.PP
|
.PP
|
||||||
|
The
|
||||||
.I option strip-height <n>
|
.I option strip-height <n>
|
||||||
, where <n> is a floating point number, limits the amount of data that is
|
, where <n> is a floating point number, limits the amount of data that is
|
||||||
read from the scanner with one read command.
|
read from the scanner with one read command.
|
||||||
The unit is inch and <n> defaults to 1.0, if this option is not set in the
|
The unit is inch and <n> defaults to 1.0,
|
||||||
configuration file. If less than <n> inch of data fit into the SCSI buffer,
|
if this option is not set in the configuration file. If less than <n> inch
|
||||||
then the smaller value is used and this option has no effect.
|
of data fit into the SCSI buffer, then the smaller value is used and this
|
||||||
|
option has no effect.
|
||||||
.PP
|
.PP
|
||||||
If your system has a big SCSI buffer and you want to make use of the whole
|
If your system has a big SCSI buffer and you want to make use of the whole
|
||||||
buffer, increase the value for <n>. For example, if <n> is set to 14.0,
|
buffer, increase the value for <n>. For example, if <n> is set to 14.0,
|
||||||
no restrictions apply for scanners with a letter, legal or A4 sized scan area.
|
no restrictions apply for scanners with a letter, legal or A4 sized
|
||||||
|
scan area.
|
||||||
.PP
|
.PP
|
||||||
.PP
|
At present the options apply to all devices in the configuration file and
|
||||||
The following options enable or disable additional frontend options. If an
|
cannnot be set on a per device basis.
|
||||||
option is set to <on> an appropriate option will appear in the frontend.
|
|
||||||
.PP
|
|
||||||
.I option no-backtrack-option <on/off>
|
|
||||||
prevents the scanner head from moving backwards between the read commands.
|
|
||||||
This speeds up scanning. Try it.
|
|
||||||
.PP
|
|
||||||
.I option lightlid-35 <on/off>
|
|
||||||
If you use the LightLid-35 transparency adapter you get an advanced
|
|
||||||
option which switches off the flatbed lamp during the scan.
|
|
||||||
.PP
|
|
||||||
.I option toggle-lamp <on/off>
|
|
||||||
You get a button in the frontend where you can switch on and off the flatbed
|
|
||||||
lamp.
|
|
||||||
.PP
|
|
||||||
.I option lineart-autoadjust <on/off>
|
|
||||||
You can tell the backend to try to determine a good value for the lineart
|
|
||||||
threshold.
|
|
||||||
.PP
|
|
||||||
.I option backend-calibration <on/off>
|
|
||||||
Some scanners (e.g. Phantom 330CX and 636CX) need to have calibrated the data
|
|
||||||
by the backend. Try this option if you see vertical stripes in your pictures.
|
|
||||||
.PP
|
|
||||||
.I option colorbalance-adjust <on/off>
|
|
||||||
Some scanners (e.g. Phantom 330CX and 636CX) need to have corrected
|
|
||||||
the color balance. If this option is enabled you get advanced options
|
|
||||||
where you can balance the colors. And you will have a button
|
|
||||||
to use the values that the firmware of the scanner provides.
|
|
||||||
.PP
|
.PP
|
||||||
A sample configuration file is shown below:
|
A sample configuration file is shown below:
|
||||||
.PP
|
.PP
|
||||||
|
@ -256,46 +126,27 @@ option strip-height 1.0
|
||||||
.br
|
.br
|
||||||
/dev/scanner
|
/dev/scanner
|
||||||
.br
|
.br
|
||||||
option no-backtrack-option on
|
|
||||||
.br
|
|
||||||
# this is a comment
|
# this is a comment
|
||||||
.br
|
.br
|
||||||
/dev/sge
|
/dev/sge
|
||||||
.br
|
|
||||||
option lightlid-35 on
|
|
||||||
.RE
|
.RE
|
||||||
|
|
||||||
This backend also supports the new configuration file format which makes
|
This backend also supports the new configuration file format which makes
|
||||||
it easier to detect scanners under Linux. If you have only one scanner it
|
it easier to detect scanners under Linux. If you have only one scanner it
|
||||||
would be best to use the following configuration file for this backend:
|
would be best to use the configuration file for this backend, that
|
||||||
|
is distributed with SANE. This file is shown below:
|
||||||
.PP
|
.PP
|
||||||
.RS
|
.RS
|
||||||
option dump 1
|
option dump 1
|
||||||
.br
|
.br
|
||||||
option strip-height 14.0
|
option strip-height 14.0
|
||||||
.br
|
.br
|
||||||
option no-backtrack-option on
|
|
||||||
.br
|
|
||||||
option backend-calibration on
|
|
||||||
.br
|
|
||||||
option lightlid-35 on
|
|
||||||
.br
|
|
||||||
option toggle-lamp on
|
|
||||||
.br
|
|
||||||
option lineart-autoadjust on
|
|
||||||
.br
|
|
||||||
option colorbalance-adjust off
|
|
||||||
.br
|
|
||||||
scsi * * Scanner
|
scsi * * Scanner
|
||||||
.RE
|
.RE
|
||||||
|
|
||||||
In this case all SCSI-Scanners should be detected automatically because of the
|
In this case all SCSI-Scanners should be detected automatically.
|
||||||
.PP
|
|
||||||
scsi * * Scanner
|
|
||||||
.PP
|
|
||||||
line.
|
|
||||||
|
|
||||||
.SH "FILES"
|
.SH FILES
|
||||||
.TP
|
.TP
|
||||||
.I @CONFIGDIR@/microtek2.conf
|
.I @CONFIGDIR@/microtek2.conf
|
||||||
The backend configuration file.
|
The backend configuration file.
|
||||||
|
@ -306,12 +157,12 @@ The static library implementing this backend.
|
||||||
.I @LIBDIR@/libsane-microtek2.so
|
.I @LIBDIR@/libsane-microtek2.so
|
||||||
The shared library implementing this backend (present on systems that
|
The shared library implementing this backend (present on systems that
|
||||||
support dynamic loading).
|
support dynamic loading).
|
||||||
.SH "ENVIRONMENT"
|
.SH ENVIRONMENT
|
||||||
.TP
|
.TP
|
||||||
.B SANE_DEBUG_MICROTEK2
|
.B SANE_DEBUG_MICROTEK2
|
||||||
If the library was compiled with debug support enabled, this
|
If the library was compiled with debug support enabled, this
|
||||||
environment variable controls the debug level for this backend. E.g.,
|
environment variable controls the debug level for this backend. E.g.,
|
||||||
a value of 255 requests all debug output to be printed. Smaller
|
a value of 128 requests all debug output to be printed. Smaller
|
||||||
levels reduce verbosity. To see error messages on stderr set
|
levels reduce verbosity. To see error messages on stderr set
|
||||||
SANE_DEBUG_MICROTEK2 to 1 (Remark: The whole debugging levels should
|
SANE_DEBUG_MICROTEK2 to 1 (Remark: The whole debugging levels should
|
||||||
be better revised).
|
be better revised).
|
||||||
|
@ -320,13 +171,6 @@ E.g. just say:
|
||||||
.br
|
.br
|
||||||
export SANE_DEBUG_MICROTEK2=128
|
export SANE_DEBUG_MICROTEK2=128
|
||||||
.SH "SEE ALSO"
|
.SH "SEE ALSO"
|
||||||
sane-scsi(5), sane(7)
|
sane-scsi(5)
|
||||||
.SH "AUTHORS"
|
.SH AUTHOR
|
||||||
Bernd Schroeder (not active anymore)
|
Bernd Schroeder
|
||||||
.br
|
|
||||||
Karsten Festag karsten.festag@t-online.de
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -15,113 +15,28 @@
|
||||||
You should have received a copy of the GNU General Public License
|
You should have received a copy of the GNU General Public License
|
||||||
along with sane; see the file COPYING. If not, write to the Free
|
along with sane; see the file COPYING. If not, write to the Free
|
||||||
Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
||||||
*/
|
|
||||||
|
|
||||||
/** @file sanei.h
|
This file declares SANE internal routines that are provided to
|
||||||
* Convenience macros and function declarations for backends
|
simplify backend implementation. */
|
||||||
* @sa sanei_backend.h sanei_thread.h
|
|
||||||
*/
|
|
||||||
|
|
||||||
/* Doxygen documentation */
|
|
||||||
|
|
||||||
/** @mainpage SANEI (SANE internal routines) documentation
|
|
||||||
*
|
|
||||||
* @image html ../sane-logo2.jpg
|
|
||||||
* @section intro Introduction
|
|
||||||
*
|
|
||||||
* The header files in the include/sane/ directory named sanei_*.h provide
|
|
||||||
* function declarations and macros that can be used by every SANE backend.
|
|
||||||
* Their implementations can be found in the sanei/ directory. The code aims
|
|
||||||
* to be platform-independent to avoid lots of \#ifdef code in the backends.
|
|
||||||
* Please use the SANEI functions wherever possible.
|
|
||||||
*
|
|
||||||
* This documentation was created by the use of doxygen, the
|
|
||||||
* doc/doxygen-sanei.conf configuration file and dcoumentation in the sanei_*.h
|
|
||||||
* files.
|
|
||||||
*
|
|
||||||
* This documenation is far from complete. Any help is appreciated.
|
|
||||||
*
|
|
||||||
* @section additional Additional documentation
|
|
||||||
* - The SANE standard can be found at <a
|
|
||||||
* href="http://www.mostang.com/sane/html/">the SANE webserver</a>.
|
|
||||||
* - Information on how to write a backend: <a
|
|
||||||
* href="../backend-writing.txt">backend-writing.txt</a>.
|
|
||||||
* - General SANE documentation is on <a
|
|
||||||
* href="http://www.mostang.com/sane/docs.html>the SANE documentation
|
|
||||||
* page</a>.
|
|
||||||
*
|
|
||||||
* @section contact Contact
|
|
||||||
*
|
|
||||||
* The common way to contact the developers of SANE is the sane-devel
|
|
||||||
* mailing list. See the <a
|
|
||||||
* href="http://www.mostang.com/sane/mail.html">mailing list webpage</a>
|
|
||||||
* for details. That's the place to ask questions, report bugs, or announce
|
|
||||||
* a new backend.
|
|
||||||
*
|
|
||||||
*/
|
|
||||||
|
|
||||||
#ifndef sanei_h
|
#ifndef sanei_h
|
||||||
#define sanei_h
|
#define sanei_h
|
||||||
|
|
||||||
#include <sane/sane.h>
|
#include <sane/sane.h>
|
||||||
|
|
||||||
/** @name Public macros and functions
|
|
||||||
* @{
|
|
||||||
*/
|
|
||||||
/** @def STRINGIFY(x)
|
|
||||||
* Turn parameter into string.
|
|
||||||
*/
|
|
||||||
/** @def PASTE(x,y)
|
|
||||||
* Concatenate parameters.
|
|
||||||
*
|
|
||||||
*/
|
|
||||||
/** @def NELEMS(a)
|
|
||||||
* Return number of elements of an array.
|
|
||||||
*
|
|
||||||
*/
|
|
||||||
/** @fn extern SANE_Status sanei_constrain_value (const SANE_Option_Descriptor * opt, void * value, SANE_Word * info);
|
|
||||||
* Check the constraints of a SANE option and adjust its value if necessary.
|
|
||||||
*
|
|
||||||
* Depending on the type of the option and constraint, value is modified
|
|
||||||
* to fit inside constraint.
|
|
||||||
*
|
|
||||||
* @param opt option to check
|
|
||||||
* @param value value of the option
|
|
||||||
* @param info info is set to SANE_INFO_INEXACT if value was changed
|
|
||||||
*
|
|
||||||
* @return
|
|
||||||
* - SANE_STATUS_GOOD - on success
|
|
||||||
* - SANE_STATUS_INVAL - if the function wasn't able to fit value into the
|
|
||||||
* constraint or any other error occured
|
|
||||||
*/
|
|
||||||
/* @} */
|
|
||||||
|
|
||||||
/** @name Private macros
|
|
||||||
* @{
|
|
||||||
*/
|
|
||||||
/** @def STRINGIFY1(x)
|
|
||||||
* Internal use only.
|
|
||||||
*/
|
|
||||||
/** @def PASTE1(x,y)
|
|
||||||
* Internal use only.
|
|
||||||
*/
|
|
||||||
/* @} */
|
|
||||||
|
|
||||||
/* A few convenience macros: */
|
/* A few convenience macros: */
|
||||||
/** @hideinitializer */
|
|
||||||
#define NELEMS(a) ((int)(sizeof (a) / sizeof (a[0])))
|
|
||||||
|
|
||||||
/** @hideinitializer */
|
|
||||||
#define STRINGIFY1(x) #x
|
#define STRINGIFY1(x) #x
|
||||||
/** @hideinitializer */
|
|
||||||
#define STRINGIFY(x) STRINGIFY1(x)
|
#define STRINGIFY(x) STRINGIFY1(x)
|
||||||
|
|
||||||
/** @hideinitializer */
|
|
||||||
#define PASTE1(x,y) x##y
|
#define PASTE1(x,y) x##y
|
||||||
/** @hideinitializer */
|
|
||||||
#define PASTE(x,y) PASTE1(x,y)
|
#define PASTE(x,y) PASTE1(x,y)
|
||||||
|
|
||||||
|
#define NELEMS(a) ((int)(sizeof (a) / sizeof (a[0])))
|
||||||
|
|
||||||
extern SANE_Status sanei_constrain_value (const SANE_Option_Descriptor * opt,
|
extern SANE_Status sanei_constrain_value (const SANE_Option_Descriptor * opt,
|
||||||
void * value, SANE_Word * info);
|
void * value, SANE_Word * info);
|
||||||
|
extern int sanei_save_values (int fd, SANE_Handle device);
|
||||||
|
extern int sanei_load_values (int fd, SANE_Handle device);
|
||||||
|
|
||||||
#endif /* sanei_h */
|
#endif /* sanei_h */
|
||||||
|
|
|
@ -37,25 +37,6 @@
|
||||||
If you write modifications of your own for SANE, it is your choice
|
If you write modifications of your own for SANE, it is your choice
|
||||||
whether to permit this exception to apply to your modifications.
|
whether to permit this exception to apply to your modifications.
|
||||||
If you do not wish that, delete this exception notice. */
|
If you do not wish that, delete this exception notice. */
|
||||||
|
|
||||||
|
|
||||||
/** @file sanei_ab306.h
|
|
||||||
* Support for the Mustek-proprietary SCSI-over-parallel-port
|
|
||||||
* interface AB306.
|
|
||||||
*
|
|
||||||
* This chip is used by the Mustek Paragon 600 II N. It's similar to a parport
|
|
||||||
* but has it's own ISA card and cable.
|
|
||||||
*
|
|
||||||
* /dev/port access is used where available. If this doesn't work, inb/outb
|
|
||||||
* functions or inb/outb assembler code is used.
|
|
||||||
*
|
|
||||||
* Depending on the operating system it may be necessary to run this code as
|
|
||||||
* root.
|
|
||||||
*
|
|
||||||
* @sa sanei_pio.h sanei_scsi.h sanei_usb.h
|
|
||||||
*/
|
|
||||||
|
|
||||||
|
|
||||||
#ifndef sanei_ab306_h
|
#ifndef sanei_ab306_h
|
||||||
#define sanei_ab306_h
|
#define sanei_ab306_h
|
||||||
|
|
||||||
|
@ -63,95 +44,14 @@
|
||||||
|
|
||||||
#include <sane/sane.h>
|
#include <sane/sane.h>
|
||||||
|
|
||||||
/**
|
|
||||||
* Open the connection to an AB306 device.
|
|
||||||
*
|
|
||||||
* The scanner is also turned on.
|
|
||||||
*
|
|
||||||
* @param dev Port address as text.
|
|
||||||
* @param fd Information about port address and I/O method. fd is not a file
|
|
||||||
* descriptor. The name and type are used for compatibility reasons.
|
|
||||||
*
|
|
||||||
* @return
|
|
||||||
* - SANE_STATUS_GOOD - on success
|
|
||||||
* - SANE_STATUS_INVAL - if the port address can't be interpreted
|
|
||||||
* - SANE_STATUS_IO_ERROR - if the device file for a port couldn't be accessed
|
|
||||||
*/
|
|
||||||
SANE_Status sanei_ab306_open (const char *dev, int *fd);
|
SANE_Status sanei_ab306_open (const char *dev, int *fd);
|
||||||
|
|
||||||
/**
|
|
||||||
* Close the connection to an AB306 device.
|
|
||||||
*
|
|
||||||
* @param fd Information about port address and I/O method.
|
|
||||||
*
|
|
||||||
*/
|
|
||||||
void sanei_ab306_close (int fd);
|
void sanei_ab306_close (int fd);
|
||||||
|
|
||||||
/**
|
|
||||||
* Exit ab306.
|
|
||||||
*
|
|
||||||
* Also powers down all devices.
|
|
||||||
*
|
|
||||||
*/
|
|
||||||
void sanei_ab306_exit (void);
|
void sanei_ab306_exit (void);
|
||||||
|
|
||||||
/**
|
|
||||||
* Get the permission for direct access to the ports.
|
|
||||||
*
|
|
||||||
* The only occasion this function must be called, is when the I/O privilege
|
|
||||||
* was lost, e.g. after forking. Otherwise, it's called automatically by
|
|
||||||
* sanei_ab306_open().
|
|
||||||
*
|
|
||||||
* @param fd Information about port address and I/O method.
|
|
||||||
*
|
|
||||||
* @return
|
|
||||||
* - SANE_STATUS_GOOD - on success
|
|
||||||
* - SANE_STATUS_IO_ERROR - if the i/o privilege was denied by the operating
|
|
||||||
* system
|
|
||||||
*/
|
|
||||||
SANE_Status sanei_ab306_get_io_privilege (int fd);
|
SANE_Status sanei_ab306_get_io_privilege (int fd);
|
||||||
/**
|
|
||||||
* Find out if the device is ready to accept new commands.
|
|
||||||
*
|
|
||||||
* @param fd Information about port address and I/O method.
|
|
||||||
*
|
|
||||||
* @return
|
|
||||||
* - SANE_STATUS_GOOD - if the device is ready
|
|
||||||
* - SANE_STATUS_DEVICE_BUSY if the device is still busy (try again later)
|
|
||||||
*/
|
|
||||||
SANE_Status sanei_ab306_test_ready (int fd);
|
SANE_Status sanei_ab306_test_ready (int fd);
|
||||||
|
|
||||||
/**
|
|
||||||
* Send a command to the AB306 device.
|
|
||||||
*
|
|
||||||
* @param fd Information about port address and I/O method.
|
|
||||||
* @param src Data to be sent to the device.
|
|
||||||
* @param src_size Size of data to be sent to the device.
|
|
||||||
* @param dst Data to be received from the device.
|
|
||||||
* @param dst_size Size of data to be received from the device
|
|
||||||
*
|
|
||||||
* @return
|
|
||||||
* - SANE_STATUS_GOOD - on success
|
|
||||||
* - SANE_STATUS_IO_ERROR - if an error occured during the dialog with the
|
|
||||||
* device
|
|
||||||
*/
|
|
||||||
SANE_Status sanei_ab306_cmd (int fd, const void *src, size_t src_size,
|
SANE_Status sanei_ab306_cmd (int fd, const void *src, size_t src_size,
|
||||||
void *dst, size_t *dst_size);
|
void *dst, size_t *dst_size);
|
||||||
|
|
||||||
/**
|
|
||||||
* Read scanned image data.
|
|
||||||
*
|
|
||||||
* @param fd Information about port address and I/O method.
|
|
||||||
* @param planes Bytes per pixel (3 for color, 1 for all other modes)
|
|
||||||
* @param buf Buffer for image data.
|
|
||||||
* @param lines Number of lines
|
|
||||||
* @param bpl Bytes per line
|
|
||||||
*
|
|
||||||
* @return
|
|
||||||
* - SANE_STATUS_GOOD - on success
|
|
||||||
* - SANE_STATUS_IO_ERROR - if an error occured during the dialog with the
|
|
||||||
* device
|
|
||||||
*/
|
|
||||||
SANE_Status sanei_ab306_rdata (int fd, int planes,
|
SANE_Status sanei_ab306_rdata (int fd, int planes,
|
||||||
SANE_Byte *buf, int lines, int bpl);
|
SANE_Byte *buf, int lines, int bpl);
|
||||||
|
|
||||||
|
|
|
@ -1,45 +1,35 @@
|
||||||
/** @file sanei_backend.h
|
|
||||||
* Compatibility header file for backends
|
|
||||||
*
|
|
||||||
* This file provides some defines for macros missing on some platforms.
|
|
||||||
* It also has the SANE API entry points. sanei_backend.h muste be included
|
|
||||||
* by every backend.
|
|
||||||
*
|
|
||||||
* @sa sanei.h sanei_thread.h
|
|
||||||
*/
|
|
||||||
|
|
||||||
/** @name Compatibility macros
|
|
||||||
* @{
|
|
||||||
*/
|
|
||||||
|
|
||||||
#include <sane/sanei_debug.h>
|
#include <sane/sanei_debug.h>
|
||||||
|
|
||||||
#ifdef HAVE_SYS_HW_H
|
#ifdef HAVE_SYS_HW_H
|
||||||
/* OS/2 i/o-port access compatibility macros: */
|
/* OS/2 i/o-port access compatibility macros: */
|
||||||
# define inb(p) _inp8 (p)
|
# define inb(p) _inp8 (p)
|
||||||
# define outb(v,p) _outp8 ((p),(v))
|
# define outb(v,p) _outp8 ((p),(v))
|
||||||
# define ioperm(b,l,o) _portaccess ((b),(b)+(l)-1)
|
# define ioperm(b,l,o) _portaccess ((b),(b)+(l)-1)
|
||||||
# define HAVE_IOPERM 1
|
# define HAVE_IOPERM 1
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifndef HAVE_OS2_H
|
|
||||||
#include <fcntl.h>
|
|
||||||
#ifndef O_NONBLOCK
|
#ifndef O_NONBLOCK
|
||||||
# ifdef O_NDELAY
|
# ifdef O_NDELAY
|
||||||
# define O_NONBLOCK O_NDELAY
|
# define O_NONBLOCK O_NDELAY
|
||||||
# else
|
# else
|
||||||
# define O_NONBLOCK FNDELAY /* last resort */
|
# define O_NONBLOCK FNDELAY /* last resort */
|
||||||
# endif
|
# endif
|
||||||
#endif
|
#endif
|
||||||
#endif /* HAVE_OS2_H */
|
|
||||||
|
|
||||||
#include <limits.h>
|
#ifndef __GLIBC__
|
||||||
#ifndef PATH_MAX
|
# ifndef u_int8_t
|
||||||
# define PATH_MAX 1024
|
# define u_int8_t unsigned char
|
||||||
|
# endif
|
||||||
|
# ifndef u_int16_t
|
||||||
|
# define u_int16_t unsigned short
|
||||||
|
# endif
|
||||||
|
# ifndef u_int32_t
|
||||||
|
# define u_int32_t unsigned int
|
||||||
|
# endif
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef HAVE_SIGPROCMASK
|
#ifdef HAVE_SIGPROCMASK
|
||||||
# define SIGACTION sigaction
|
# define SIGACTION sigaction
|
||||||
#else
|
#else
|
||||||
|
|
||||||
/* Just enough backwards compatibility that we get by in the backends
|
/* Just enough backwards compatibility that we get by in the backends
|
||||||
|
@ -72,38 +62,35 @@
|
||||||
# undef SIG_SETMASK
|
# undef SIG_SETMASK
|
||||||
# endif
|
# endif
|
||||||
|
|
||||||
# define sigset_t int
|
# define sigset_t int
|
||||||
# define sigemptyset(set) do { *(set) = 0; } while (0)
|
# define sigemptyset(set) do { *(set) = 0; } while (0)
|
||||||
# define sigfillset(set) do { *(set) = ~0; } while (0)
|
# define sigfillset(set) do { *(set) = ~0; } while (0)
|
||||||
# define sigaddset(set,signal) do { *(set) |= sigmask (signal); } while (0)
|
# define sigaddset(set,signal) do { *(set) |= sigmask (signal); } while (0)
|
||||||
# define sigdelset(set,signal) do { *(set) &= ~sigmask (signal); } while (0)
|
# define sigdelset(set,signal) do { *(set) &= ~sigmask (signal); } while (0)
|
||||||
# define sigaction(sig,new,old) sigvec (sig,new,old)
|
# define sigaction(sig,new,old) sigvec (sig,new,old)
|
||||||
|
|
||||||
/* Note: it's not safe to just declare our own "struct sigaction" since
|
/* Note: it's not safe to just declare our own "struct sigaction" since
|
||||||
some systems (e.g., some versions of OpenStep) declare that structure,
|
some systems (e.g., some versions of OpenStep) declare that structure,
|
||||||
but do not implement sigprocmask(). Hard to believe, aint it? */
|
but do not implement sigprocmask(). Hard to believe, aint it? */
|
||||||
# define SIGACTION sigvec
|
# define SIGACTION sigvec
|
||||||
# define SIG_BLOCK 1
|
# define SIG_BLOCK 1
|
||||||
# define SIG_UNBLOCK 2
|
# define SIG_UNBLOCK 2
|
||||||
# define SIG_SETMASK 3
|
# define SIG_SETMASK 3
|
||||||
#endif /* !HAVE_SIGPROCMASK */
|
#endif /* !HAVE_SIGPROCMASK */
|
||||||
/* @} */
|
|
||||||
|
|
||||||
|
/* Declare the entry points: */
|
||||||
|
|
||||||
/** @name Declaration of entry points:
|
|
||||||
* @{
|
|
||||||
*/
|
|
||||||
extern SANE_Status ENTRY(init) (SANE_Int *, SANE_Auth_Callback);
|
extern SANE_Status ENTRY(init) (SANE_Int *, SANE_Auth_Callback);
|
||||||
extern SANE_Status ENTRY(get_devices) (const SANE_Device ***, SANE_Bool);
|
extern SANE_Status ENTRY(get_devices) (const SANE_Device ***, SANE_Bool);
|
||||||
extern SANE_Status ENTRY(open) (SANE_String_Const, SANE_Handle *);
|
extern SANE_Status ENTRY(open) (SANE_String_Const, SANE_Handle *);
|
||||||
extern const SANE_Option_Descriptor *
|
extern const SANE_Option_Descriptor *
|
||||||
ENTRY(get_option_descriptor) (SANE_Handle, SANE_Int);
|
ENTRY(get_option_descriptor) (SANE_Handle, SANE_Int);
|
||||||
extern SANE_Status ENTRY(control_option) (SANE_Handle, SANE_Int, SANE_Action,
|
extern SANE_Status ENTRY(control_option) (SANE_Handle, SANE_Int, SANE_Action,
|
||||||
void *, SANE_Word *);
|
void *, SANE_Word *);
|
||||||
extern SANE_Status ENTRY(get_parameters) (SANE_Handle, SANE_Parameters *);
|
extern SANE_Status ENTRY(get_parameters) (SANE_Handle, SANE_Parameters *);
|
||||||
extern SANE_Status ENTRY(start) (SANE_Handle);
|
extern SANE_Status ENTRY(start) (SANE_Handle);
|
||||||
extern SANE_Status ENTRY(read) (SANE_Handle, SANE_Byte *, SANE_Int,
|
extern SANE_Status ENTRY(read) (SANE_Handle, SANE_Byte *, SANE_Int,
|
||||||
SANE_Int *);
|
SANE_Int *);
|
||||||
extern SANE_Status ENTRY(set_io_mode) (SANE_Handle, SANE_Bool);
|
extern SANE_Status ENTRY(set_io_mode) (SANE_Handle, SANE_Bool);
|
||||||
extern SANE_Status ENTRY(get_select_fd) (SANE_Handle, SANE_Int *);
|
extern SANE_Status ENTRY(get_select_fd) (SANE_Handle, SANE_Int *);
|
||||||
extern void ENTRY(cancel) (SANE_Handle);
|
extern void ENTRY(cancel) (SANE_Handle);
|
||||||
|
@ -113,28 +100,17 @@ extern void ENTRY(exit) (void);
|
||||||
#ifndef STUBS
|
#ifndef STUBS
|
||||||
/* Now redirect sane_* calls to backend's functions: */
|
/* Now redirect sane_* calls to backend's functions: */
|
||||||
|
|
||||||
#define sane_init(a,b) ENTRY(init) (a,b)
|
#define sane_init(a,b) ENTRY(init) (a,b)
|
||||||
#define sane_get_devices(a,b) ENTRY(get_devices) (a,b)
|
#define sane_get_devices(a,b) ENTRY(get_devices) (a,b)
|
||||||
#define sane_open(a,b) ENTRY(open) (a,b)
|
#define sane_open(a,b) ENTRY(open) (a,b)
|
||||||
#define sane_get_option_descriptor(a,b) ENTRY(get_option_descriptor) (a,b)
|
#define sane_get_option_descriptor(a,b) ENTRY(get_option_descriptor) (a,b)
|
||||||
#define sane_control_option(a,b,c,d,e) ENTRY(control_option) (a,b,c,d,e)
|
#define sane_control_option(a,b,c,d,e) ENTRY(control_option) (a,b,c,d,e)
|
||||||
#define sane_get_parameters(a,b) ENTRY(get_parameters) (a,b)
|
#define sane_get_parameters(a,b) ENTRY(get_parameters) (a,b)
|
||||||
#define sane_start(a) ENTRY(start) (a)
|
#define sane_start(a) ENTRY(start) (a)
|
||||||
#define sane_read(a,b,c,d) ENTRY(read) (a,b,c,d)
|
#define sane_read(a,b,c,d) ENTRY(read) (a,b,c,d)
|
||||||
#define sane_set_io_mode(a,b) ENTRY(set_io_mode) (a,b)
|
#define sane_set_io_mode(a,b) ENTRY(set_io_mode) (a,b)
|
||||||
#define sane_get_select_fd(a,b) ENTRY(get_select_fd) (a,b)
|
#define sane_get_select_fd(a,b) ENTRY(get_select_fd) (a,b)
|
||||||
#define sane_cancel(a) ENTRY(cancel) (a)
|
#define sane_cancel(a) ENTRY(cancel) (a)
|
||||||
#define sane_close(a) ENTRY(close) (a)
|
#define sane_close(a) ENTRY(close) (a)
|
||||||
#define sane_exit(a) ENTRY(exit) (a)
|
#define sane_exit(a) ENTRY(exit) (a)
|
||||||
#endif /* STUBS */
|
#endif /* STUBS */
|
||||||
/* @} */
|
|
||||||
|
|
||||||
/** @name Internationalization for SANE backends
|
|
||||||
* Add SANE_I18N() to all texts that can be translated.
|
|
||||||
* E.g. out_txt = SANE_I18N("Hello");
|
|
||||||
* @{
|
|
||||||
*/
|
|
||||||
#ifndef SANE_I18N
|
|
||||||
#define SANE_I18N(text) text
|
|
||||||
#endif
|
|
||||||
/* @} */
|
|
||||||
|
|
|
@ -15,27 +15,12 @@
|
||||||
You should have received a copy of the GNU General Public License
|
You should have received a copy of the GNU General Public License
|
||||||
along with sane; see the file COPYING. If not, write to the Free
|
along with sane; see the file COPYING. If not, write to the Free
|
||||||
Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
||||||
*/
|
|
||||||
|
|
||||||
/** @file sanei_codec_ascii.h
|
This file declares SANE application interface. See the SANE
|
||||||
* ASCII codec for network and file transmissions
|
standard for a detailed explanation of the interface. */
|
||||||
*
|
|
||||||
* Instead translating data to a byte stream this codec uses ASCII hex numbers.
|
|
||||||
* Therefore it can be used for streams that are not 8-bit clean or which can
|
|
||||||
* only use printable characters. It's currently used for saving/restoring
|
|
||||||
* data to/from disk.
|
|
||||||
*
|
|
||||||
* @sa sanei_codec_bin.h sanei_net.h sanei_wire.h
|
|
||||||
*/
|
|
||||||
#ifndef sanei_codec_ascii_h
|
#ifndef sanei_codec_ascii_h
|
||||||
#define sanei_codec_ascii_h
|
#define sanei_codec_ascii_h
|
||||||
|
|
||||||
/** Initialize the ascii codec
|
|
||||||
*
|
|
||||||
* Set the i/o functions of the Wire to those of the ASCII codec.
|
|
||||||
*
|
|
||||||
* @param w Wire
|
|
||||||
*/
|
|
||||||
extern void sanei_codec_ascii_init (Wire *w);
|
extern void sanei_codec_ascii_init (Wire *w);
|
||||||
|
|
||||||
#endif /* sanei_codec_ascii_h */
|
#endif /* sanei_codec_ascii_h */
|
||||||
|
|
|
@ -15,25 +15,12 @@
|
||||||
You should have received a copy of the GNU General Public License
|
You should have received a copy of the GNU General Public License
|
||||||
along with sane; see the file COPYING. If not, write to the Free
|
along with sane; see the file COPYING. If not, write to the Free
|
||||||
Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
||||||
*/
|
|
||||||
/** @file sanei_codec_bin.h
|
|
||||||
* Binary codec for network transmissions
|
|
||||||
*
|
|
||||||
* Transtale data to a byte stream while taking byte order problems into
|
|
||||||
* account. This codec is currently used for saned and the network backend.
|
|
||||||
*
|
|
||||||
* @sa sanei_codec_ascii.h sanei_net.h sanei_wire.h
|
|
||||||
*/
|
|
||||||
|
|
||||||
|
This file declares SANE application interface. See the SANE
|
||||||
|
standard for a detailed explanation of the interface. */
|
||||||
#ifndef sanei_codec_bin_h
|
#ifndef sanei_codec_bin_h
|
||||||
#define sanei_codec_bin_h
|
#define sanei_codec_bin_h
|
||||||
|
|
||||||
/** Initialize the binary codec
|
|
||||||
*
|
|
||||||
* Set the i/o functions of the Wire to those of the binary codec.
|
|
||||||
*
|
|
||||||
* @param w Wire
|
|
||||||
*/
|
|
||||||
extern void sanei_codec_bin_init (Wire *w);
|
extern void sanei_codec_bin_init (Wire *w);
|
||||||
|
|
||||||
#endif /* sanei_codec_bin_h */
|
#endif /* sanei_codec_bin_h */
|
||||||
|
|
|
@ -37,91 +37,40 @@
|
||||||
If you write modifications of your own for SANE, it is your choice
|
If you write modifications of your own for SANE, it is your choice
|
||||||
whether to permit this exception to apply to your modifications.
|
whether to permit this exception to apply to your modifications.
|
||||||
If you do not wish that, delete this exception notice.
|
If you do not wish that, delete this exception notice.
|
||||||
*/
|
|
||||||
|
|
||||||
/** @file sanei_config.h
|
This file provides generic configuration support. */
|
||||||
* Generic configuration support.
|
|
||||||
*
|
|
||||||
* Use the functions of this header file if you want to read and analyze
|
|
||||||
* configuration files.
|
|
||||||
*/
|
|
||||||
|
|
||||||
#ifndef sanei_config_h
|
#ifndef sanei_config_h
|
||||||
|
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
|
|
||||||
/** Search configuration file \a name along directory list and return file
|
|
||||||
* pointer if such a file exists.
|
|
||||||
*
|
|
||||||
* The following directory list is used:
|
|
||||||
* 1st: SANE_CONFIG_DIR environment variable.
|
|
||||||
* 2nd: PATH_SANE_CONFIG_DIR set during configuration.
|
|
||||||
* 3rd: Current directory.
|
|
||||||
* @param name filename with extension but without path (such as "mustek.conf")
|
|
||||||
*
|
|
||||||
* @return file pointer, or NULL if not found
|
|
||||||
*
|
|
||||||
*/
|
|
||||||
extern FILE *sanei_config_open (const char *name);
|
extern FILE *sanei_config_open (const char *name);
|
||||||
|
|
||||||
/** Read a line from configuration file.
|
|
||||||
*
|
|
||||||
* Strips all unwanted chars. Use this instead of fgets() to remove
|
|
||||||
* line ending chars on all known platforms.
|
|
||||||
*
|
|
||||||
* @param str points to the buffer for the line
|
|
||||||
* @param n size of the buffer
|
|
||||||
* @param stream file pointer
|
|
||||||
*
|
|
||||||
* @return \a str on success and NULL on error
|
|
||||||
*/
|
|
||||||
extern char *sanei_config_read (char *str, int n, FILE *stream);
|
|
||||||
|
|
||||||
/** Remove all whitespace from the beginning of a string.
|
|
||||||
*
|
|
||||||
* @param str string
|
|
||||||
*
|
|
||||||
* @return string without leading whitespace
|
|
||||||
*
|
|
||||||
*/
|
|
||||||
extern const char *sanei_config_skip_whitespace (const char *str);
|
extern const char *sanei_config_skip_whitespace (const char *str);
|
||||||
|
/* Scan a string constant from the string pointed to by STR and return
|
||||||
|
a malloced copy of it in *STRING_CONST (it's the responsibility of
|
||||||
/** Scan a string constant from a line of text and return a malloced copy
|
the caller to free the returned string at an appropriate time).
|
||||||
* of it.
|
Whitespace in front of the string constant is ignored. Whitespace
|
||||||
*
|
can be included in the string constant by enclosing it in
|
||||||
* It's the responsibility of the caller to free the returned string constant
|
double-quotes. A return val of NULL indicates that no string
|
||||||
* at an appropriate time. Whitespace in front of the string constant is
|
constant was found. */
|
||||||
* ignored. Whitespace can be included in the string constant by enclosing it
|
|
||||||
* in double-quotes.
|
|
||||||
*
|
|
||||||
* @param str line of text to scan for a string constant
|
|
||||||
* @param string_const copy of the string constant
|
|
||||||
*
|
|
||||||
* @return a pointer to the position in str where the scan stopped
|
|
||||||
*/
|
|
||||||
extern const char *sanei_config_get_string (const char *str,
|
extern const char *sanei_config_get_string (const char *str,
|
||||||
char **string_const);
|
char **string_const);
|
||||||
|
|
||||||
/** Expand device name patterns into a list of devices.
|
/* A convenience function to support expanding device name patterns
|
||||||
*
|
into a list of devices. Apart from a normal device name
|
||||||
* Apart from a normal device name (such as /dev/sdb), this function currently
|
(such as /dev/sdb), this function currently supports SCSI
|
||||||
* supports SCSI device specifications of the form:
|
device specifications of the form:
|
||||||
*
|
|
||||||
* scsi VENDOR MODEL TYPE BUS CHANNEL ID LUN
|
scsi VENDOR MODEL TYPE BUS CHANNEL ID LUN
|
||||||
*
|
|
||||||
* Where VENDOR is the desired vendor name. MODEL is the desired model name.
|
Where VENDOR is the desired vendor name. MODEL is the desired
|
||||||
* TYPE is the desired device type. All of these can be set to * to match
|
MODEL name. TYPE is the desired device type. All of these can be
|
||||||
* anything. To include whitespace in these strings, enclose them in
|
set to * to match anything. To include whitespace in these
|
||||||
* double-quotes ("). BUS, ID, and LUN are the desired SCSI bus, id, and
|
strings, enclose them in double-quotes ("). BUS, ID, and LUN are
|
||||||
* logical-unit numbers. These can be set to * or simply omitted to match
|
the desired SCSI bus, id, and logical-unit numbers. These can be
|
||||||
* anything.
|
set to * or simply omitted to match anything. */
|
||||||
*
|
|
||||||
* @param name device name pattern
|
|
||||||
* @param attach attach function
|
|
||||||
*/
|
|
||||||
extern void sanei_config_attach_matching_devices (const char *name,
|
extern void sanei_config_attach_matching_devices (const char *name,
|
||||||
SANE_Status (*attach)
|
SANE_Status (*attach)
|
||||||
(const char *dev));
|
(const char *dev));
|
||||||
|
|
||||||
#endif /* sanei_config_h */
|
#endif /* sanei_config_h */
|
||||||
|
|
|
@ -1,176 +1,51 @@
|
||||||
/** @file sanei_debug.h
|
|
||||||
* Support for printing debug messages.
|
|
||||||
*
|
|
||||||
* Use the functions of this header file to print debug or warning messages.
|
|
||||||
*/
|
|
||||||
|
|
||||||
#ifndef _SANEI_DEBUG_H
|
|
||||||
#define _SANEI_DEBUG_H
|
|
||||||
|
|
||||||
#include <sane/sanei.h>
|
#include <sane/sanei.h>
|
||||||
|
|
||||||
/** @name Public macros
|
#define ENTRY(name) PASTE(PASTE(PASTE(sane_,BACKEND_NAME),_),name)
|
||||||
* These macros can be used in backends and other SANE-related
|
|
||||||
* code.
|
|
||||||
*
|
|
||||||
* Before including sanei_debug.h, the following macros must be set:
|
|
||||||
*
|
|
||||||
* - BACKEND_NAME - The name of your backend without double-quotes (must be set in any case)
|
|
||||||
* - STUBS - If this is defined, no macros will be included. Used in
|
|
||||||
* backends consisting of more than one .c file.
|
|
||||||
* - DEBUG_DECLARE_ONLY - Generates prototypes instead of functions. Used in
|
|
||||||
* backends consisting of more than one .c file.
|
|
||||||
* - DEBUG_NOT_STATIC - Doesn't generate static functions. Used in header files if
|
|
||||||
* they are include in more than one .c file.
|
|
||||||
*
|
|
||||||
* @{
|
|
||||||
*/
|
|
||||||
|
|
||||||
/** @def DBG_INIT()
|
/* The cpp that comes with GNU C 2.5 seems to have troubles understanding
|
||||||
* Initialize sanei_debug.
|
vararg macros. */
|
||||||
*
|
#if __GNUC__ - 0 > 2 || (__GNUC__ - 0 == 2 && __GNUC_MINOR__ > 5)
|
||||||
* Call this function before you use any DBG function.
|
# define HAVE_VARARG_MACROS
|
||||||
*/
|
#endif
|
||||||
|
|
||||||
/** @def DBG(level, fmt, ...)
|
#ifndef HAVE_VARARG_MACROS
|
||||||
* Print a message at debug level `level' or higher using a printf-like
|
extern void sanei_debug (int level, const char *msg, ...);
|
||||||
* function. Example: DBG(1, "sane_open: opening fd \%d\\n", fd).
|
#endif
|
||||||
*
|
|
||||||
* @param level debug level
|
|
||||||
* @param fmt format (see man 3 printf for details)
|
|
||||||
* @param ... additional arguments
|
|
||||||
*/
|
|
||||||
|
|
||||||
/** @def IF_DBG(x)
|
|
||||||
* Compile code only if debugging is enabled.
|
|
||||||
*
|
|
||||||
* Expands to x if debug support is enabled at compile-time. If NDEBUG is
|
|
||||||
* defined at compile-time this macro expands to nothing.
|
|
||||||
*
|
|
||||||
* @param x code to expand when debugging is enabled
|
|
||||||
*/
|
|
||||||
|
|
||||||
/**
|
|
||||||
* @def DBG_LEVEL
|
|
||||||
* Current debug level.
|
|
||||||
*
|
|
||||||
* You can only read this "variable".
|
|
||||||
*/
|
|
||||||
|
|
||||||
/** @def ENTRY(name)
|
|
||||||
* Expands to sane_BACKEND_NAME_name.
|
|
||||||
*
|
|
||||||
* Example: ENTRY(init) in mustek.c will expand to sane_mustek_init.
|
|
||||||
*/
|
|
||||||
|
|
||||||
/* @} */
|
|
||||||
|
|
||||||
/** @name Internal macros and functions
|
|
||||||
* Do not use in your own code.
|
|
||||||
* @{
|
|
||||||
*/
|
|
||||||
|
|
||||||
/** @def DBG_LOCAL
|
|
||||||
* Do not use in backends directly.
|
|
||||||
*
|
|
||||||
* Internal wrapper for printing function.
|
|
||||||
*/
|
|
||||||
|
|
||||||
/** @fn extern void sanei_init_debug (const char * backend, int * debug_level_var);
|
|
||||||
* Do not use in backends directly.
|
|
||||||
*
|
|
||||||
* Actual init function.
|
|
||||||
*/
|
|
||||||
|
|
||||||
/** @fn extern void sanei_debug_msg (int level, int max_level, const char *be, const char *fmt, va_list ap);
|
|
||||||
* Do not use in backends directly.
|
|
||||||
*
|
|
||||||
* Actual printing function.
|
|
||||||
*/
|
|
||||||
/* @} */
|
|
||||||
|
|
||||||
/** @hideinitializer*/
|
|
||||||
#define ENTRY(name) PASTE(PASTE(PASTE(sane_,BACKEND_NAME),_),name)
|
|
||||||
|
|
||||||
#ifdef NDEBUG
|
#ifdef NDEBUG
|
||||||
|
# define DBG_INIT(backend, var)
|
||||||
extern void sanei_debug_ndebug (int level, const char *msg, ...);
|
# ifdef HAVE_VARARG_MACROS
|
||||||
|
# define DBG(level, msg, args...)
|
||||||
# define DBG_LEVEL (0)
|
# else
|
||||||
# define DBG_INIT()
|
# define DBG if (0) sanei_debug
|
||||||
# define DBG sanei_debug_ndebug
|
# endif
|
||||||
# define IF_DBG(x)
|
# define IF_DBG(x)
|
||||||
|
#else
|
||||||
#else /* !NDEBUG */
|
# include <stdio.h>
|
||||||
|
|
||||||
/** @hideinitializer*/
|
|
||||||
# define DBG_LEVEL PASTE(sanei_debug_,BACKEND_NAME)
|
|
||||||
|
|
||||||
# if defined(BACKEND_NAME) && !defined(STUBS)
|
#define DBG_LEVEL PASTE(sanei_debug_,BACKEND_NAME)
|
||||||
# ifdef DEBUG_DECLARE_ONLY
|
|
||||||
extern int DBG_LEVEL;
|
|
||||||
# else /* !DEBUG_DECLARE_ONLY */
|
|
||||||
int DBG_LEVEL = 0;
|
|
||||||
# endif /* DEBUG_DECLARE_ONLY */
|
|
||||||
# endif /* BACKEND_NAME && !STUBS */
|
|
||||||
|
|
||||||
/** @hideinitializer*/
|
#if defined(BACKEND_NAME) && !defined(STUBS)
|
||||||
# define DBG_INIT() \
|
int PASTE(sanei_debug_,BACKEND_NAME);
|
||||||
sanei_init_debug (STRINGIFY(BACKEND_NAME), &DBG_LEVEL)
|
|
||||||
|
|
||||||
/** @hideinitializer*/
|
|
||||||
# define DBG_LOCAL PASTE(DBG_LEVEL,_call)
|
|
||||||
|
|
||||||
|
|
||||||
# ifndef STUBS
|
|
||||||
|
|
||||||
# ifdef DEBUG_DECLARE_ONLY
|
|
||||||
|
|
||||||
extern void DBG_LOCAL (int level, const char *msg, ...)
|
|
||||||
#ifdef __GNUC__
|
|
||||||
__attribute__ ((format (printf, 2, 3)))
|
|
||||||
#endif
|
#endif
|
||||||
;
|
|
||||||
|
|
||||||
# else /* !DEBUG_DECLARE_ONLY */
|
# define DBG_INIT() \
|
||||||
|
sanei_init_debug (STRINGIFY(BACKEND_NAME), \
|
||||||
|
&PASTE(sanei_debug_,BACKEND_NAME))
|
||||||
|
|
||||||
# include <stdarg.h>
|
/* The cpp that comes with GNU C 2.5 seems to have troubles understanding
|
||||||
|
vararg macros. */
|
||||||
extern void sanei_debug_msg
|
#ifdef HAVE_VARARG_MACROS
|
||||||
(int level, int max_level, const char *be, const char *fmt, va_list ap);
|
# define DBG(level, msg, args...) \
|
||||||
|
do { \
|
||||||
|
if (DBG_LEVEL >= (level)) \
|
||||||
|
fprintf (stderr, "[" STRINGIFY(BACKEND_NAME) "] " msg, ##args); \
|
||||||
|
} while (0)
|
||||||
|
|
||||||
#ifdef __GNUC__
|
extern void sanei_init_debug (const char * backend, int * debug_level_var);
|
||||||
# ifndef DEBUG_NOT_STATIC
|
#else
|
||||||
static
|
# define DBG sanei_debug
|
||||||
# endif /* !DEBUG_NOT_STATIC */
|
#endif
|
||||||
void DBG_LOCAL (int level, const char *msg, ...) __attribute__ ((format (printf, 2, 3)));
|
|
||||||
#endif /* __GNUC__ */
|
|
||||||
|
|
||||||
# ifndef DEBUG_NOT_STATIC
|
# define IF_DBG(x) x
|
||||||
static
|
#endif
|
||||||
# endif /* !DEBUG_NOT_STATIC */
|
|
||||||
void
|
|
||||||
DBG_LOCAL (int level, const char *msg, ...)
|
|
||||||
{
|
|
||||||
va_list ap;
|
|
||||||
|
|
||||||
va_start (ap, msg);
|
|
||||||
sanei_debug_msg (level, DBG_LEVEL, STRINGIFY(BACKEND_NAME), msg, ap);
|
|
||||||
va_end (ap);
|
|
||||||
}
|
|
||||||
|
|
||||||
# endif /* DEBUG_DECLARE_ONLY */
|
|
||||||
|
|
||||||
# endif /* !STUBS */
|
|
||||||
|
|
||||||
/** @hideinitializer*/
|
|
||||||
# define DBG DBG_LOCAL
|
|
||||||
|
|
||||||
extern void sanei_init_debug (const char * backend, int * debug_level_var);
|
|
||||||
|
|
||||||
/** @hideinitializer*/
|
|
||||||
# define IF_DBG(x) x
|
|
||||||
|
|
||||||
#endif /* NDEBUG */
|
|
||||||
|
|
||||||
#endif /* _SANEI_DEBUG_H */
|
|
||||||
|
|
Ładowanie…
Reference in New Issue