Home | Christian Missions | Christustreff Marburg | Pictures of Marburg | Job | Remote Communications | Linux OS | Psion page | Contact

horizontal rule in rainbow colours (2,1 kB)

How To Scan under Linux with a Mustek ScanMagic P 4800

Log of Investigations and Attempts

Environment

Literature Research

Even the HOWTO-list of the Linux Documentation Project is remarkably silent on the subject of scanning.

The traditional means of scanner access is SANE (Scanner Access Now Easy).

The fact that it is a parallel port scanner makes things really hard, because most drivers are there for SCSI-scanners.

The Sane compatibility page lists an alpha driver for the Mustek ScanMagic 4800 P: mustek_pp, which has a homepage (on the developer's site) and a man page (on the SANE site).

Installation

1. Find out, whether I have a current version of SANE

locate sane shows a bunch of dlls indicating version 1.0.2. The current version according to ftp://ftp.mostang.com/pub/sane/ is 1.0.4.

2. Download Sources

So download sane-frontends-1.0.4.tar.gz, sane-backends-1.0.4.tar.gz, xsane-0.76.tar.gz and mustek_pp-6.alpha.tar.gz (from the developer's homepage).

3. Deinstall whatever SuSE 7.0 has installed

Login as root, start YaST, delete packages sane and xsane.

4. Install SANE

The mustek_pp home page says, that sanei_pa4s2 interface is not needed if SANE 1.0.3 or later is used - this will be the case, so I'll skip a4s2.

The section on mustec_pp indicates, that the SANE distribution should only be compiled after mustek_pp is untarred.

From here on I go along section 4 (How do I install) of the Sane FAQ. I'll only note exceptions and peculiarities.

untar in /usr/local/src/, resulting in /usr/local/src/sane-backends-1.0.4.

It already contains mustek_pp version 9, so I'll ignore the downloaded version 6.

Do the usual ./configure; make; make install.

5. Configure SANE

The configuration files reside in /usr/local/etc/sane.d.

Edit dll.conf in order to enable only the existing scanner and net (that's going to be used for non-root scanning).

Edit mustek_pp.conf: make sure ONLY the options of my scanner are enabled.

Try to detect the scanner by running as root scanimage -L which says "device `mustek_pp:SM-4800P' is a Mustek MFS-600IIIP flatbed scanner". Fine.

6. Compile Frontends

cd /usr/local/src; tar xzvf /home/stut/download/sane/xsane-0.76.tar.gz; cd xsane-0.76/; ./configure

complains about missing gtk-devel, so I install that from the SuSE-CDs. Now ./configure works.

Same with sane-frontends.

Problem now: a call to xsane or xscanimage (in a ssh root shell within KDE) results in "Gtk-WARNING **: cannot open display:". So:

7. Setup saned network access to the scanner

See also man saned (1).

Edit /usr/local/etc/sane.d/saned.conf to include localhost and a few hosts on the local appartment network.

Edit /etc/services to contain a line sane 6566/tcp # SANE network scanner daemon

Edit /etc/inetd.conf to contain a line sane stream tcp nowait root.root /usr/local/sbin/saned saned

I know that running saned as root is not the most secure idea, but the devie logics don't leave me with a different choice.

Don't forget to restart inetd after this.

8. Tell the client to use the network

See man sane-net (5).

Edit /usr/local/etc/sane.d/net.conf to contain a line localhost

Now a non-privileged (run by an ordinary user) call of scanimage -L results in the scanner!

xscanimage does work flawlessly now!

horizontal rule in rainbow colours (2,1 kB)

Home | Christian Missions | Christustreff Marburg | Pictures of Marburg | Job | Remote Communications | Linux OS | Psion page | Contact


Last updated: 05.05.2007 17:43:13 Martin Stut, email: email address as image, Marburg, Germany
URL: http://www.stut.de/linuxscan.html