This is a PytQt5 desktop app for rapidly scanning documents by using the Scan-to-Folder button on HP Multi Function Printers (MFP) especially CM Devices.
This app uses the Sane backend to get all parameters needed.
It also provides image enhancement features.
Note: in this version only the first scanner is used
NEW: Config profiles
If you want scan document with different page sizes it may usefull to save each configuration into a seperate profile
OCR processing and PDF-Document creation or from local images.
The Scan2Folder-Button has a new function.
By pressing the button it opens a file dialog where you can select your image files
you want to procees.
Note: the filenames must be numbered like this<filename>_[1..n].png
OCR processing and PDF-Document creation from your scanns.
After you finished scanning, you can start an OCR-Process The OCR-Process will do the following steps:
- Deskew each page
- Crop the image
- Check text orientation
- Start ocr
- Create searchable PDF
You can define the crop size in the configuration dialog
Note: In this version A4 page size for 300dpi is predifned. If you want to change this, you can do it in ocrtools.py
- Ensure that your scanner is reachable
- Start the app
- Select a ScanMode
- Select a path where you want to store your images
- Enter an image prefix name. All the scanned images will enumerated automatically.
- Choose a scan resolution
- Press the Start Service button
If the scanner is reachable the LED turns on green and you can use the scan-to-folder button on your device.
On clicking the Config/Calibrate
menu opens a window where you can scan a preview image.
Note: the scan button is only enabled when the service is running.
Only flatbed scanning is supported
Install packages needed with:
sudo pip3 install -r deps/dependency.txt
Install tesseract-ocr 4 with your language and with Orientation & Script detection
In the bin directory a spec
file for pyinstaller
is provided
Calling #> pyinstaller scan2folder.spec
creates a single executable binary for your environment
Have a look at the pyinstaller doc for more information
- creates PDF from local images
- spec file for creating stand alone binaries
- Image name is cleared when stopped a scan session
- Image name has now auto complete, to avoid overwrite existing files
- The script is tested only with a HP CM1312 device
- Only one (the first) scanner is usable
- If the LED does not become green after the device is switched on, may be your device is not supported
- If the LED becomes green and the button keeps yellow, the scanner is locked by another device/thread
Nicolas Bernaerts who inspired me with his script