Skip to main content

Dynamsoft Barcode Reader Python project

Project description

Dynamsoft Barcode Reader

Build status

Dynamsoft Barcode Reader SDK enables you to efficiently embed barcode reading functionality in your web, desktop and mobile application using just a few lines of code. This can save you months of added development time and extra costs. With our SDK, you can create high-speed and reliable barcode scanner software to meet your business needs.

Environment

Python 2/3

Supported Symbologies

  • Linear Barcodes (1D)

    • Code 39 (including Code 39 Extended)
    • Code 93
    • Code 128
    • Codabar
    • Interleaved 2 of 5
    • EAN-8
    • EAN-13
    • UPC-A
    • UPC-E
    • Industrial 2 of 5
  • 2D Barcodes:

    • QR Code (including Micro QR Code)
    • Data Matrix
    • PDF417 (including Micro PDF417)
    • Aztec Code
    • MaxiCode (mode 2-5)
  • Patch Code

  • GS1 DataBar (Omnidirectional, Truncated, Stacked, Stacked Omnidirectional, Limited, Expanded, Expanded Stacked)

  • GS1 Composite Code

How to Install and Use the SDK

Install Dynamsoft Barcode Reader:

pip install dbr

A simple Python barcode reader app:

from dbr import DynamsoftBarcodeReader
dbr = DynamsoftBarcodeReader()
dbr.initLicense('YOUR-LICENSE') # https://www.dynamsoft.com/CustomerPortal/Portal/Triallicense.aspx
results = dbr.decodeFile(fileName, dbr.BF_ONED | dbr.BF_PDF417 | dbr.BF_QR_CODE | dbr.BF_DATAMATRIX | dbr.BF_AZTEC)
for result in results:
    print("barcode format: " + result[0])
    print("barcode value: " + result[1])

Screenshot

webcam barcode reader with OpenCV Python

Functions

  • initLicense(license-key)

  • decodeFile(filename, barcodeTypes)

    barcodeTypes = dbr.BF_ONED | dbr.BF_PDF417 | dbr.BF_QR_CODE | dbr.BF_DATAMATRIX | dbr.BF_AZTEC 
    
    Barcode Format Values
    ALL dbr.BF_ALL
    1D dbr.BF_ONED
    PDF417 dbr.BF_PDF417
    QR Code dbr.BF_QR_CODE
    DataMatrix dbr.BF_DATAMATRIX
    Aztec Code dbr.BF_AZTEC
  • decodeBuffer(frame-by-opencv-capture, barcodeTypes)

  • decodeFileStream(fileStream, fileSzie, barcodeTypes)

  • startVideoMode(max_buffer, max_results, video_width, video_height, image_format, barcodeTypes, callback)

  • stopVideoMode()

  • appendVideoFrame(frame-by-opencv-capture)

  • initLicenseFromLicenseContent(license-key, license-content)

  • outputLicenseToString()

  • initLicenseFromServer(license-key, license-server)

  • setFurtherModes(mode, [values])

  • setParameters(json-string)

Online Documentation

https://www.dynamsoft.com/Products/Barcode-Reader-Resources.aspx#documentation

Contact

support@dynamsoft.com

Project details


Download files

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

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distributions

dbr-7.2.1-cp38-cp38-win_amd64.whl (6.8 MB view hashes)

Uploaded CPython 3.8 Windows x86-64

dbr-7.2.1-cp37-cp37m-win_amd64.whl (6.8 MB view hashes)

Uploaded CPython 3.7m Windows x86-64

dbr-7.2.1-cp36-cp36m-win_amd64.whl (6.8 MB view hashes)

Uploaded CPython 3.6m Windows x86-64

dbr-7.2.1-cp35-cp35m-win_amd64.whl (6.8 MB view hashes)

Uploaded CPython 3.5m Windows x86-64

dbr-7.2.1-cp27-cp27m-win_amd64.whl (6.8 MB view hashes)

Uploaded CPython 2.7m Windows x86-64

Supported by

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