meta data for this page
This is an old revision of the document!
SANE
SANE - Scanner Access Now Easy
Sane frontends in Debian
- xsane
- xscanimage - simple GUI, scans directly to file, not possible to view scanned image
- simple-scan - perfect to fast scanning of books, etc ,very simple GUI (photo/text) to create multi-pages documents (view of live scan)
- [https://gitlab.gnome.org/GNOME/simple-scan|project page]
- [-] brightness/contasrt adjustments doesn't work
- skanlite - works slowly, performs some USB polling
- gscan2pdf
Sane backend
apt-get install sane xsane sane-utils usermod -aG scanner user usermod -aG lp saned
Prepare udev rules to give access permission to USB:
- Download and extract udev rules from: ScanGear MP package
- rules are inside `CONTENTS.cpio` file
sudo udevadm control --reload-rules
sudo udevadm trigger --action=add --subsystem-match=usb
List scanners:
scanimage -L
Canon Lide 400
Bus 001 Device 003: ID 04a9:1912 Canon, Inc.
proprietary
Download and install Canon's ScanGear debian package.
This package provides no compatibility with sane, it provides own tool scangearmp2
sane
From sane list, it should be supproted by sane-pixma driver: Backend: pixma (0.23.0)
Build as DEB
apt-get install build-essential fakeroot devscripts
manual download
Download source package from https://packages.debian.org/unstable/source/sane-backends:
- sane-backends_1.0.31-4.dsc
- sane-backends_1.0.31.orig.tar.gz
- sane-backends_1.0.31-4.debian.tar.xz
dpkg-source -x sane-backends_1.0.31-4.dsc cd sane-backends-1.0.31 dpkg-checkbuilddeps sudo mk-build-deps -i # sudo apt-get install libcurl4-gnutls-dev dpkg -i ../sane-backends.deb
apt source download
apt-get source sane-backends cd sane-backends-1.0.27
build
apt-get build-dep sane-backends debuild -b -uc -us dpkg -i ../sane-backends.deb
Build from source
Remove files installed by distribution:
sudo apt-get purge libsane-extras
apt-get install libjpeg-dev libpng-dev libpoppler-glib-dev git clone https://gitlab.com/sane-project/backends.git
read INSTALL.linux how to install
libsane.so: undefined reference to `libusb_set_option' Solution: check for old libusb in /usr/local/lib. Mine was from microchip IDE.
Download daily snapshoot from: http://www.sane-project.org/snapshots/
apt-get install libjpeg-dev libpng-dev libpoppler-glib-dev libglib2.0-dev ./configure make sudo make install sudo ldconfig
Now it works:
$ scanimage -L device `pixma:04A91912_413B3B' is a CANON CanoScan LiDE 400 multi-function peripheral device `pixma:04A91912' is a CANON CanoScan LiDE 400 multi-function peripheral
gamma adjust
Scanner backends supports custom gamma table of size 1024 (10bits). Color range is from 0 to 65535. To get raw color scan from scanner:
scanimage --custom-gamma=yes --gamma-table `gamma4scanimage 1.0 0 1023 1023 65535` >image.pnm