Skip to main content

A simple python CLI tool to connect to HP scanner devices over local network and scan documents with ease.

Project description

HPScanCLI

The HPScanCLI is a command-line interface for interacting with HP scanners through their web interfaces. It allows to search for available printers in the local network, print out printer capabilities, and initiate scans with various parameters.

Features

  • Search for Printers: Discover HP printers available in the local network.
  • Print Capabilities: Retrieve and display the capabilities of a printer.
  • Scan Documents: Initiate scanning operations with customizable parameters like DPI, height, width, color mode, and output format.

Requirements

  • Python 3.x
  • Required Python packages (bs4, requests)

Installation

  1. Clone the repository:

    git clone https://github.com/prasannareddych/HPScanCLI.git
    
  2. Install the required packages:

    pip install -r requirements.txt
    

Usage

Run the script from the command line with appropriate options:

hpscancli [options]

Command-line Options

  • -i, --ip: IP address of the HP Wireless scanner / InkTank / LaserJet.
  • -s, --searchprinter: search for available printers in the network.
  • -c, --capabilities: show capabilities of the printer.
  • --height: set scan height.
  • --width: Set scan width.
  • --dpi: set scan DPI.
  • --colormode: set scan color mode.
  • --pdf: set output format to PDF.
  • -o, --output: set output filename.
  • -b, --bulkscan: scan in bulk mode.

Examples

  1. Search for available printers:

    hpscancli -s
    
  2. Print capabilities of a specific printer:

    hpscancli -i <printer-ip> -c
    
  3. Perform a scan with custom parameters:

    hpscancli -i <printer-ip> --height 1200 --width 800 --dpi 300 --colormode RGB24 --pdf -o scan1
    

Author

Prasanna Reddy. Ch

License

This project is licensed under the MIT License - see the LICENSE file for details.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

hpscancli-1.0.0.tar.gz (6.3 kB view details)

Uploaded Source

File details

Details for the file hpscancli-1.0.0.tar.gz.

File metadata

  • Download URL: hpscancli-1.0.0.tar.gz
  • Upload date:
  • Size: 6.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.0.0 CPython/3.11.6

File hashes

Hashes for hpscancli-1.0.0.tar.gz
Algorithm Hash digest
SHA256 a9a00542a9c4ae734cc4a232a79e20d10269fb1bc1d9b9ed0579ba3b3b3c37ec
MD5 2b2aa189799d25769ae77e8e7ee175df
BLAKE2b-256 43901de4b594d315243de96fb0730b6c54e86cbf81f065b498c9d2af96adf694

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page