Not sure which Scandit product fits your use case?
Install our data-capture-sdk skill so your coding agent can answer questions about Scandit products and recommend the right one for your use case, directly from your editor. More info →
Run this in a terminal in your project directory, then follow the instructions to select your coding agent.
npx skills add https://github.com/scandit/skills --skill data-capture-sdkYour coding agent loads the skill automatically based on your prompt; to invoke it explicitly, call /data-capture-sdk followed by your task.
Sample Programs
This page provides a list of sample programs that demonstrate how to use the Scandit Data Capture SDK for C / Linux.
All sample applications are contained the samples directory of the SDK package.
Prerequisites
Before you begin, make sure you have the following prerequisites in place for the relevant samples:
Scanner Samples
Requires Video4Linux2 for camera access, install it with:
$ sudo apt-get install libv4l-dev`
Image Processing Samples
If using C, requires SDL2 for loading images, install it with:
$ sudo apt-get install libsdl2-dev libsdl2-image-dev
If using Python3, requires SDL2 for python3 also for image loading, install it with:
$ sudo apt-get install python3-sdl2
Barcode Generator Sample
Requires libpng for generating the output image, install it with:
$ sudo apt-get install libpng-dev
License Key
You must insert your license key to all sample source files before compiling and running them. Sign up for a free trial if you don't already have a license key.
Running the Samples
To run the samples, follow these steps:
- Open a terminal and navigate to the SDK package directory.
- Compile the samples.
$ cd samples
$ make - Execute the desired sample program, for example:
$ ./CommandLineBarcodeScannerImageProcessingSample ean13-code.png