#!/bin/bash sudo modprobe aic7xxx sudo modprobe sg cd $HOME/.tmp rm -f image-* export filename=`date +'%s'` #8939343 = 2549 * 3507 if [ $# -eq 1 ]; then export filename=$1 fi sudo scanadf --resolution 600 --emphasis High -e 1 --source FB -d fujitsu --raw --mode Lineart --compression MMR cd - ls $HOME/.tmp/image-* | xargs python ../raw2pdf/raw2pdf.py > $filename.pdf