GS4500 scanner driver
=====================

This is a device driver that supports the Genius GS4500 handheld scanner and 
also the GS4500A. It operates as a loadable kernel module.

Version 2.0 is a version which the major change is to allow the use of the 
Genius GS4500A and to select the IRQ or DMA ports when the scanner allows to 
select them via software. The select function wasn't work and this version
correct it. A new mode has been added to use a feature only present in the GS4500A
which we called SingleShotMode and consists of reading from the scanner even 
without pressing the button neither to move the scanner.

This release only supports Linux kernels 2.0.x. If you are still working
with a 1.2.x kernel, you have to use version 1.4 of this scanner driver.
 
Compiling the driver
====================
 
First you have to create /dev/gs4500 with a matching major device number
("mknod /dev/gs4500 c 16 0") and create a link to /dev/scanner
("ln -s /dev/gs4500 /dev/scanner").

Now you have to compile the driver. You will probably have to edit the 
Makefile and comment or uncomment the line where we define the GS4500A 
variable. If you have a GS4500 comment that line. If you have a GS4500A 
uncomment it. You can also change the place where you want the driver to be
kept changing variable MODULEDIR and change some other things changing 
variables in the Makefile.
 
Finaly, to compile the driver just type "make". If you want to install the
driver in its final place, type "make install".
 
Installing the driver
=====================
 
To install the driver as a loadable module you have to put some lines in your 
/etc/conf.modules file. You have to put this line to tell the kerneld what is 
the name of the driver:
 
alias char-major-16 gs4500.o
 
If you have a GS4500 don't add more lines because the driver will autodetect
the jumpers selection on the board of the scanner. If you have a GS4500A you 
will have to tell the driver which are the IRQ and DMA that you want to use.
 
options gs4500 gs_dma=3 gs_irq=9
 
Just change 3 and 9 to reflect the DMA and IRQ you want. Possible IRQs are 3 or0 and possible DMAs are 1 or 3. When using the GS4500A options, you HAVE to 
choose one IRQ and one DMA.
If somehow the driver don't select the proper address just tell it the address of the scanner adding to the previous line the option:
 
gs_data=0x272
 
where 0x272 should be the ioport of the scanner.
 
If you want to install the driver without the auto-loading feature just load it
with insmod using the following line:
 
insmod gs4500.o
 
However, if you have a GS4500A you should write something like this:
 
insmod gs4500.o gs_irq=9 gs_dma=3
 
To understand the meening of the option just read the text, refering to 
the auto-loading feature.
 
Known Problems
==============
 
The default setting for the GS4500 ioport (Bank 1: 272h - 27Bh) conflict
with the default ioports of /dev/lpt2 (278h - 27Fh). Welcome to the
funny world of PC hardware...
Make sure you only use one device on those ports!
 
You can use "cat /dev/ioports" to see wich ports are in use. Remember
to load you printer module before checking.
 
Supported Scanner
=================
 
- Genius GeniScan GS4500
- Genius GeniScan GS4500A
? Genius GeniScan GS4000 (DOS drivers for the GS4000 work
  with my GS4500 so I'd assume this driver works with a
  GS4000)


New Features:
 *      - added the support for GS4500A
 *      - added single-shot-mode (GS4500A only)
 *      - added a new IOCTL to enter and exit single-shot-mode
 *      - Allow the specification of the IRQ and DMA port we want to use
 *        when loading the module instead of autodetection (important
 *        for the GS4500A)
 *      - the select function is now working
 *      - small changes here and there...
 
Scanning applications
=====================

We still need a killer application to do enduser scanning.

Included is gifscan where I added the P command so you can
save images als PBM bitmaps. (Saving as GIF is too slow to be usable
on my machine.) There is probably a newer version of gifscan out, so
you might want to check your nearest ftp site. In theory all handheld
scanner drivers have a compatible interface, so you should have no
problem using the scanning software from other distributions.

A modified version of xscan 1.1 is also included.
 
Let me know if you have problems with the driver. I'll try to fix them.
Please let me also know what exact scanner type you used it with
successfully (other than GeniScan GS4500 and GS4500A).

 
Authors:
========

Jan Willamowius (jan@janhh.shnet.org)
	http://swt-www.informatik.uni-hamburg.de/~1willamo/ 
Richard Lyons (rick@enterprise.powerup.com.au)
Pedro Maia Alves (l41096@alfa.ist.utl.pt)

