Testing scanners under Linux

Scan It

© Lead Image © wbraga, 123RF.com

© Lead Image © wbraga, 123RF.com

Article from Issue 211/2018
Author(s):

Using scanners to digitize documents in Linux was once a perilous business, but Linux scanner technology has improved in recent years. We study the state of the art with some leading scanners from various manufacturers.

If the paperless office were already a reality, no one would need a scanner anymore. But wherever you look in the corporate environment today, you very quickly see that traditionalists continue to defend the ubiquitous role of scanners in the office. And not only that, increasing numbers of multifunction printers with integrated scanning units are being used in home offices and by private users.

Electronics stores continue to sell dedicated flatbed scanners, as well as equipment for special applications. This includes devices for mobile use, but also document scanners that automatically digitize large volumes of documents (see the "Big Devices" box). This article investigates how this device farm gets along with Linux.

Big Devices

Many manufacturers offer large standalone devices with scanning units, some of which also work with Linux. However, under Linux these multifunction devices are mostly used as pure printers for workstations on the intranet. They are not suitable as scanners for ordinary client systems.

Since such business devices are primarily aimed at large departments or branches, the scanning units are mostly used to digitize documents directly on the device and then integrate them into the company's internal workflow. This is usually done via touchscreens, often with an integrated keyboard and corresponding menu navigation. The digitized documents can then be mailed or integrated directly into a groupware solution.

Standards

When scanners gradually became affordable for smaller companies in the early 1990s, a consortium of various hardware and software manufacturers developed the TWAIN specification. It defines a uniform interface for controlling scanners from within applications. While the TWAIN interface was initially only developed for Microsoft and Apple operating systems, version 2.0 also has supported Linux [1] from 2008.

At the same time, Linux developers have been working since 1996 on a unified interface for imaging devices called Scanner Access Now Easy (SANE) [2], which they released under the GPLv2. It is divided into a front end and a back end, with the two being strictly isolated. The back end forms the interface between the operating system and the scanner or camera hardware, and the front ends integrate into corresponding applications, making it possible to control the hardware and use its capabilities.

Thanks to this concept, all common front ends cooperate with the SANE back end without time-consuming adjustments. This explains why SANE is now considered the quasi-standard for scanners under Linux. Graphical applications like XSane [3], xscanimage [4], Simple Scan [5], or KDE Skanlite [6] all rely on it.

VueScan [7] is a commercial solution for Linux, which American Ed Hamrickhas been working on since 1999. It uses proprietary drivers and drivers from scanner manufacturers. The software supports more than 4,500 scanner models under Linux and is available in two versions. Both offer the same GUI, but differ in terms of functionality and price [8].

In addition to the two quasi-standards, manufacturers of scanners and multifunctional devices offer their own front ends, which generally use SANE as the back end. Some of them provide their own modules for SANE in order to make hardware that has only been on the market for a short time usable under Linux.

Test Subjects

In our lab, Linux (Pro) Magazine looked at devices from a wide variety of applications. The field extends from multifunctional devices with scanning units for small and medium volumes through dedicated scanners for use in small offices, to two extremely compact models for mobile use. In addition to SANE and VueScan, the test – if available – also takes into account software solutions from the manufacturers. The test field does not include special-purpose document and mobile scanners or barcode scanners. Devices that only digitize photos and are intended for private users are also missing.

Brother DS-820W and DS-920DW

The mobile hand scanner DS-820W [9] by Japanese manufacturer Brother costs around EUR185 (~$160) and is designed as an all-round feed scanner with CIS sensor technology for mobile users (see the "Gobbledygook: CIS or CCD?" box). Thanks to an exchangeable lithium-ion battery, it even works without a stationary energy source. With the aid of a motor-driven feeder, the device can read individual pages up to A4 format, but it can also digitize plastic cards, such as ID cards, driver's licences, or customer cards.

Gobbledygook: CIS or CCD?

In the technospeak of every type of scanner's technical specifications, prospective customers will repeatedly stumble over two abbreviations: CIS and CCD. Both terms denote different constructions of the scanner's optical reading units.

Charge Coupled Device (CCD) technology uses a cold light tube as the light source, which directs the light onto a prism and then splits it into the primary colors red, green, and blue. The CCD sensor then captures each color with its own sensor line and converts it with light-sensitive capacitors and converters into numerical values that can be read by computers.

In contrast, Compact Image Sensor (CIS) scanning units rely on red, green, and blue light LEDs as light sources that use a simple rod lens to direct the light to the sensor, which in turn converts the light into computer-readable signals. Due to its simple design, the CIS scanning unit is significantly smaller than a CCD unit and also requires significantly less operating energy, but it does not provide any depth of field due to its simple design. CIS scanners cannot therefore digitize thick documents, for example books, because they do not lie flat on the scanner's glass pane.

The model is similarly flexible when it comes to storing and transferring data. The scanner talks to the host computer either via WLAN or a USB connection. There is also a slot for an SD memory card to store the digitized data. This means that the scanner can be used as a standalone device.

Brother offers Debian and RPM packages with Linux modules for download [10] for the device, which weighs around one pound. The modules are available for both 32- and 64-bit architectures.

The almost identical model Brother DS-920DW [11] costs around EUR190 (~$180), only a few Euros/dollars less than the DS-820W. It differs from its little brother only in terms of a slightly larger housing with a slightly different arrangement of the control elements and the possibility of scanning both sides of a page in a single pass (Figure 1).

Figure 1: Externally almost identical: Brother DS-820W (back) and DS-920DW (front).

The small device has a second CIS scan array, which you can switch on and off via the scanner's keypad. This explains why the DS-920DW weighs slightly more than the simplex scanner.

The driver modules are identical for both scanners. Larger infrastructures, in which both scanners work, do not require a separate module installation for each model. The installation of the driver module is very easy. First, download an appropriate deb or RPM package. Then connect the scanner to the host computer via a USB cable, switch to the command line, and install the SANE driver with admin rights as follows:

rpm -ivh --nodeps <packagename>

for RPM-based and Debian-based distributions, use the following command:

dpkg -i --force-all <packagename>

You then check to see if this step has integrated the module into the system by entering rpm -qa | grep -e dsseries or dpkg -l | grep Brother.

However, in the practical test, serious inconsistencies were revealed at times. We were able to install the modules on all test distributions without any problems, but some of them showed insurmountable weaknesses. The Russian ROSA Linux R8.1 failed to detect either scanner, although the module seemed to be correctly integrated into the system. The use of the two mobile scanners via the USB interface therefore failed under the ROSA Linux. The conversion of the deb packages to RPM format using the alien program was also unsuccessful.

Things looked different on Ubuntu 16.04 LTS and the Debian-based Q4OS (Scorpion) v2.4: The Brother scanners worked right away here. They not only achieved good scanning results with very different front ends, but also made a positive impression due to their very fast working speed.

Because it turned out to be difficult to integrate Brother's mobile scanners under ROSA Linux, I started additional tests with further distributions of both package management formats. These included Linux Mint 18.1, Mageia 6, and openSUSE Leap 42.2 and 42.3. The latest variant of ROSA Linux Desktop Fresh R10 was added.

The additional tests showed that the Brother models worked fine with all distributions that use the deb package format, while the driver installation via the RPM package format did not work on any distribution.

With massive overhead, it was finally possible to operate the scanners under openSUSE Leap 42.3. For this, you need to install the /etc/udev/rules.d/55-libsane.rules file with a text editor and add the following two lines at the end

# Brother
ATTR{idVendor}=="04f9", MODE="0644",   GROUP="lp", ENV{libsane_matched}="yes"

After rebooting, the system recognized the scanners without root privileges, and XSane and Skanlite were able to use the devices normally.

After installing the driver, the scanimage -L command executed with root privileges reveals whether other RPM-based distributions also detect the Brother scanners. Brother's hopelessly outdated support page, which pays homage to long lost distributions like Mandriva 2010 or Red Hat [12], is a point of criticism. Manual adjustment of the Udev rules is also considered outdated.

Brother's support for Debian-based distributions also gives cause for criticism. Although the drivers provided worked without problems, the documentation is misleading. The support pages suggest various settings that are no longer necessary for current variants. Clearing out and updating the page would be helpful. Most of the information relates to distributions that are almost 10 years old and no longer in use anywhere. At the same time, more current Linux systems that came onto the market since 2012 are missing.

Buy this article as PDF

Express-Checkout as PDF
Price $2.95
(incl. VAT)

Buy Linux Magazine

SINGLE ISSUES
 
SUBSCRIPTIONS
 
TABLET & SMARTPHONE APPS
Get it on Google Play

US / Canada

Get it on Google Play

UK / Australia

Related content

  • Command Line: SANE

    Running your scanner from the command line offers greater control of tasks. We show you how to get started.

  • Scanning with XSane

    The Sane interface provides access to image processing devices such as scanners. You can manage your Sane-supported scanner from Linux with the handy XSane front-end.

  • Tutorial – USB/IP

    The Linux kernel has many interesting but unknown services. USB/IP, in particular, is one that you'll probably wonder why you have never encountered. USB/IP lets you use USB devices connected to other machines on your network as if they were plugged directly into your computer.

  • Archivista Box with Open Source OCR

    Swiss vendor Archivista offers a document management solution comprising T2 Linux, OCR software, scanning software, archiving software and hardware. Version VIII of the GPL'd including the free OCR programs Ocrad 0.17 and Tesseract 2.0 is now available for downloading.

  • Open Note Scanner: Instant Note Digitizing on Android
comments powered by Disqus
Subscribe to our Linux Newsletters
Find Linux and Open Source Jobs
Subscribe to our ADMIN Newsletters

Support Our Work

Linux Magazine content is made possible with support from readers like you. Please consider contributing when you’ve found an article to be beneficial.

Learn More

News