ScanBooklet - Document scan controller program.
ScanBooklet {switches} <archivedate string> <PublicationTitle> \ <Publication Directory> --fp | --firstpage=str Number for initial page of document. Default is "001". -f | --format=str Scan format. The default is an A4 in Portrait: P:8.5x13 First field is orientation, L or P, for landscape or portrait. Second field is size in inches across scanner width. Third field is size in inches down scanner length. --sw | --spine=num Width of the document spine. Default is 1 inch. --scanner=s Scanner id: Default is "gt68xx:libusb:001:003". --ps | --pagesource=s Page source. Default is "NotApplicable." -d | --debug Turn on internal debug code, if any. -v ! --verbose=num Set level of diagnostic output. 0 for none. -h | --help Print this usage information. --man Print the man page for this command.
This is a command line scanner control program for working with documents. For example, to scan the 17 July 2006 issue of New Scientist, one might type:
ScanBooklet 20060717 NewScientist /path/Publications/NewScientist
to create a directory containing scans of all the pages of that issue:
/path/Publications/NewScientist/20060717-NewScientist/
Each page must be manually set up on the scan bed before typing commands.
The commands are:
a: Scan the next batch of sheets without asking questions. f: Scan sheet with title of cover. c: Scan sheet with title of contents. p: Scan sheet with default blank title. b: Scan sheet with title of backcover. s: Scan the document spine. 1: One sheet number per scan. 2: Two sheet numbers per scan. i: Print information on the current job. h: Help. q: Quit. x: eXit. CR: Stay in the same mode.
The selection of a sheet as front or back automatically set the next scan to be a single page per sheet. The assumption is that the user initialized sheet size was either for single page per sheet documents or if for sized for two pages per sheet, the document has been laid on the scan table on the right or left of the field as appropriate. The program does not change the sheet size one going from one to the other. The sheet size is fixed for a given document and must be able to fit the largest field required during the entire document scan.
Pages per sheet is limited to 1 or 2. If there are more than 2 pages in a scan field, use the numbers of the first and last pages in the field. You can even generate overlapping fields of page numbers, so long as no overlapping field has the same start and end page numbers, eg "001-002", "002-003", "004-005", "005-006", "003-006" would be one way to deal with the pages in a 3 page foldout in a magazine.
Page numbers "001" and "001-001" will both result in a filename of "filename-p001.jpeg".
If you selected the wrong sheet type and are in the page number prompt, clear the line back to the prompt and hit ^d. This will return you to the sheet type prompt without doing anything else.
A ^p uses the history list to give you the previous pages if you want to rescan.
Valid page numbers are:
001 Will increment until 999. 001a Will increment unil 001z. 000.spine No incrementing. 001.01 Will increment until 001.99. 001.01a Will increment unil 001.01z.
In unix you can use the program:
lsusb
(as root) to help you find where a usb scanner is and to help you use the "hp:libusb:001:019" format.
A few thus far known supported scanners and their valid page sources are:
Umax 1200 umax:/dev/scsi/host0/bus0/target6/lun0/generic "NotApplicable"; Old HP's: "hp:libusb:001:003" "adf" "Normal" ScanJet 5590 "hp5590:libusb:001:003" "adf" (*) "Normal" Mustek A3 USB "gt68xx:libusb:001:003" "NotApplicable" * The SANE driver for this scanner does not properly handle page feeds through the ADF. It pulls multiple pages for every single page scan request. HP says it ain't there problem and the SANE guy doesn't have time to work on it.
# Using the default scanner and A4 page size ScanBooklet 20080817 Scanner.pm-annotatedDMA /home/me/ # Specifying the scanner and page format. ScanBooklet --scanner "gt68xx:lubusb:001:003" -f "L:12x17" \ 20080817 Relativity-EinsteinEtAl /home/me/
None.
See TODO.
Term::Readline, Term::Readline::Gnu, Scanner::Device, Scanner::Job
Dale Amon <amon@vnl.com>
To install ScanBooklet, copy and paste the appropriate command in to your terminal.
cpanm
cpanm ScanBooklet
CPAN shell
perl -MCPAN -e shell install ScanBooklet
For more information on module installation, please visit the detailed CPAN module installation guide.