scanimage

scanimage [options]

Read images from devices such as scanners and cameras, writing the images to standard output in PNM (Portable aNyMap) format. scanimage uses the SANE interface to access the scanner and can support any device for which there is a SANE backend.

Formats

PBM

Black-and-white

PGM

Grayscale

PPM

Color

TIFF

Black-and-white, grayscale, or color

Options

--accept-md5-only

Only accept MD5 authorization requests.

-b [format] , --batch[=format]

Work in batch mode, using a document feeder. Each page is written to a file, as specified by format, using a printf-type string. The default format is out%d.pnm for the PNM formats and out%d.tif for TIFF.

--batch-count=num

The number of pages to scan in batch mode. Use this option for scanners that do not signal when they are empty; the default is to continue scanning until such a signal is received.

--batch-double

Increment the page number by 2 in batch mode. Used for scanning two-sided originals on a single-sided scanner.

--batch-increment=num

Increment the number in the filename by num in batch mode.

--batch-prompt

In batch mode, prompt the user to press Return before scanning a page. Useful for manually feeding multiple pages.

--batch-start=num

Specify the page number in batch mode to use in the first filename. The default is 0.

-ddevice, --device-name=device

Specify the scanner device to use—e.g., /dev/scanner.

-fformat, --formatted-device-list=format

Show the available scanner devices, as with -L, but also format the output. Possible format specifications are:

%d

Device name

%i

Index number

%m

Model

%t

Type

%v

Vendor

--format=format

Specify the file format of the output file. The possible values are pnm and tiff.

-h, --help

Print a help message and exit. You can get device-specific help by running scanimage as follows:

scanimage -h -ddevice

-iprofile, --icc-profile=profile

Include the specified ICC profile in the TIFF output file.

-L, --list-devices

Display a list of available devices. The list may not be complete, particularly when accessing scanners across the network. Only scanners listed in a configuration file (typically in the directory /etc/sane.d) are displayed. A scanner with no configuration file entry must be accessed by its full device name.

-n, --dont-scan

Set the specified options, but don't actually scan anything.

-T, --test

Run some sanity tests to be sure the backend works as defined by the SANE API.