Convenient use of the HP scanner in a local area network

    It so happened that in our office on the local network there is an HP LaserJet MFP connected to the server.
    Its printing part was shared over the entire network using standard means, but there were problems with scanning.
    Actually, they were solved by writing two scripts (PHP + bash) for the server, which allow:

    • select a scan source (top tray with auto feed for A4 sheets or flatbed scanner)
    • set the number of pages (it makes sense only for a flatbed scanner - it cannot determine when the sheets have run out)
    • if desired - immediately overtake a multi-page document in PDF
    • download the resulting file (s) to your computer

    It all looks like this:





    Scan results

    Sources: here or here or here .

    Actually, for use it is necessary:

    1. Correct variable outdir file scanme and expose him to chmod + x
    2. Correct lines 18 and 27 in the index.php file by writing IP networks and the path to the scanme script in them

    The scanimage , tiffcp and tiff2pdf utilities are called inside - you may have to deliver them from the repository / packages.

    upd. Habrauser otaqsun also suggested the phpSANE project - it is good for scanning images one at a time, but does not understand the automatic document feeder and can not overtake scan results to PDF (but it can do it in JPEG and PNM).

    Also popular now: