Overview
The Zebra Scanner Software Developer Kit (SDK) for Linux defines an architectural framework providing a single programming interface across multiple programming languages (such as C++, Java) and across multiple system environments (such as RPM based Linux distributions and Debian based Linux) for all scanner communication variants (such as IBMHID, SNAPI, and HIDKB).
The Zebra Scanner SDK includes a suite of components that provides a unified software development framework with a wide range of functions for interfacing Zebra scanners to user applications and solutions.
The CoreScanner driver creates a connection between the host and scanner. The SDK uses CoreScanner to receive data from and send commands to the scanner.
This SDK allows you to read barcodes, manage scanner configurations, capture images/videos, and select a list of scanners on which to work. While one application in one programming language uses a scanner or a set of scanners, you can use another application in a different language within the same system environment.
The SDK can build an application with complete control of scanner capabilities:
-
Data, barcode
- JPOS output
- SNAPI output
-
Command and control
- LED and beeper control
- Aim control
- Scan enable and disable
-
Imaging
- Capture and transfer of images
- Capture and transfer of video
NOTE For a list of a scanner's supported attribute (parameter) numbers and definitions, refer to the scanner Product Reference Guide, available on the Zebra Support website http://www.zebra.com/support. Attributes include configuration parameters, monitored data, and asset tracking information.
Scanner SDK Architecture
Host Communication Modes
You can configure Zebra scanner devices to operate in different host communication modes such as USB SNAPI, USB OPOS, USB HID Keyboard, and USB IBM Table-top. Device feature support varies by mode but all modes support barcode scanning. Refer to the scanner Product Reference Guide to set the host communication mode.
To use the Zebra Scanner SDK to switch between supported host communication modes, useful when advanced functionality is required but not supported by the current communication mode, call the Host Variant Switching command. This switches the scanner to a feature-rich mode to execute certain commands, and then reverts the scanner to the previous mode.
For example, to disable the UPC-A symbology when the device is in USB HID Keyboard mode, switch the scanner to USB SNAPI or USB OPOS (if supported by the scanner), disable UPC-A, and then revert the scanner to USB HID Keyboard mode.
Following table illustrates scanner capabilities supported in each communication mode. Refer to the scanner specifications for support of each communication mode.
Table 1: Scanner Device Communication Modes Vs. Capabilities
Capabilities | USB SNAPI | USB HID Keyboard | USB IBM Table-top | USB IBM Handheld |
---|---|---|---|---|
Data | Supported | Supported | Supported | Supported |
Host Variant Switching | Supported | Supported | Supported | Supported |
Management | Supported | Not Available | Supported | Supported |
Image & Video | Supported | Not Available | Not Available | Not Available |
Simulated HID Keyboard Output * | Supported | Not Available | Supported | Supported |
Advanced Data Formatting | Not Available | Supported | Partial | Partial |
Multicode Data Formatting | Supported | Supported | Supported | Supported |
*Advanced Data Formatting (ADF) is not supported when using Simulated HID Keyboard Output. |
Multiple Scanner Device Identification and Asset Tracking
The Zebra Scanner SDK supports connecting multiple scanners to any user application running on CoreScanner APIs. The application identifies each scanner by a unique scanner identification number. There cannot be multiple scanners with the same scanner ID.
Asset tracking information such as model number, serial number, firmware version, and date of manufacture is available if the scanner and its current host mode support the management feature. For example, asset tracking information does not appear for a scanner in USB HID Keyboard mode, but does appear if that scanner is in USB OPOS or USB SNAPI mode.
The format of device asset tracking information can vary between device models. For example, the length of a serial number for DS6707 and DS9808 scanners can be different.
Application Access to Multiple Scanners
The Zebra Scanner SDK supports multiple applications accessing multiple scanners connected to the host at the same time.
The scanner ID uniquely identifies a connected scanner to all applications, and is consistent among all applications for one SDK instance. Restarting the CoreScanner service or the host may assign a different scanner ID to a scanner, but it is unique and referenced by all applications.
Two Applications Connected To One Scanner
App 1 & App 2 support bi-directional (two way) communication with the scanner.
Three Applications Connected To Two Scanners
App 1 and App 2 support bi-directional (two way) communication with the DS6878.
Many Applications Connected To Many Scanners
App 1 performs image capture with the DS6878.
App 2 remotely manages both the DS6878 and LS4208.
App 3 receives OPOS data from both the DS6878 and LS4208.
One Application Connected to Two Scanners
One application can manage multiple scanners in multiple communication interfaces. The application can capture data, image, and video, send management commands, and receive responses from multiple scanners.
All scanner responses consist of details (ScannerID, serial number, model number, etc.) identifying the scanner that sent the response.
The following example shows a barcode event for a scanned label. The label data contains a unique ScannerID and the scanner's model number and serial number.
<?xml version="1.0" encoding="UTF-8"?>
<outArgs>
<scannerID>1</scannerID>
<arg-xml>
<scandata>
<modelnumber>DS6707-SR20001ZZR </modelnumber>
<serialnumber>7114000503308 </serialnumber>
<GUID>9008A01BB72BA34BB519806B63701AAA</GUID>
<datatype>11 </datatype>
<datalabel>0x39 0x37 0x38 0x30 0x32 0x30 0x31 0x34</datalabel>
<rawdata>0x39 0x37 0x38 0x30 0x32 0x30 0x31 0x34</rawdata>
</scandata>
</arg-xml>
</outArgs>
Supported Devices
For the compatible devices list, please visit following page.
https://www.zebra.com/us/en/support-downloads/software/developer-tools/scanner-sdk-for-linux.htmlSupported Linux Distributions
Scanner SDK for Linux (CoreScanner and JPOS) and IoT Connector for Linux latest versions supporting following distributions.
Active Focus Manager for Linux and Command Line Utility for Linux latest versions supporting following distributions.
Version History
Version 4.4.1-42 - 07/2024
- Added Topology change event support to CoreScanner. A PNP event will get fired when a cascaded scanner gets attached or detached.
- Added support for GS1 DataMatrix Symbology.
- Added support for HanXin and DotCode Symbology over IBMHID and IBMTT.
- Bug Fix - Fixed configuration update failure using SDK sample app/ CLU when the note section contains formatted texts (newline, tab, etc.).
- Bug Fix - Enhanced the firmware update process to accommodate combined scanner and cradle firmware.
Version 4.4.1-40 - 04/2024
-
CoreScanner Driver v4.4.1-40
- Added configuration name to "GetScanners" command outXML.
- Bug Fix - Addressed the CoreScanner segmentation fault that occurred at system shutdown.
-
JPOS Driver v4.4.1-50
- Bug Fix - Minor sample app fix - State of Data Event Enable and Device Enable checkboxes in JPOS Sample application now shows the correct state when JPOS Scale profile is not opened.
- Bug Fix - Fixed intermittent exception caused in the JPOS Scale live weight thread when attempting to restart or configure the scale while live weight is in progress.
- Bug Fix - Minor sample app fix - Synchronized state of “Device Enable” checkbox when “Auto Device Enable” or “Enable Live Weight” selections are used.
- Added a new attribute as “ClearQueueOnRelease” to JPOS.xml file, to configure clearing the data queue when device is released.
- Bug Fix - An exception is fired upon performing Zero Scale with weights greater than the firmware implemented scale zeroing weight limit.
- Bug Fix - Prevented incorrectly throwing “Timed out with zero stable weight” exception after setting PIDXScal_ZeroValid to true in JPOS Scale live weight DIO.
-
Command Line Utility (CLU) v1.0.0-6
- Added the command "assetinfo" to retrieve asset information. It returns host mode, serial number, firmware version and date of manufacture selected devices.
- Added support for returning error/status codes for the executed CLU commands.
Version 4.4.1-38 - 01/2024
- Command Line Utility (CLU) - Added new command to retrieve asset information based on scanner ID. It returns host mode, serial number, firmware version and date of manufacture of the scanner.
-
IoT Connector
- Added support for logging of environment variables (pulled from operating system) into the URL and request headers in the HTTP sink. Note the environmental variable check is performed real-time on each logging occurrence.
- Bug Fix - Rarely used scenario addressed - Full read/write permission to Corescanner log folder now available. This enables a user to read/write files to the log folder. Access permission now exists for the general user of the zebra log folder regardless of its form of creation (both created through service/created during installation).
Version 4.4.1-36 - 10/2023
- Bug Fix - Record count sent with firmware update progress events functions as expected; Intermittent issue addressed.
- Bug Fix - Changed default value of "bulktransfer_time_out>" in configuration file to resolve scanner reboot issue seen during firmware update.
- Bug Fix - Command Line Utility (CLU) - Resolved a firmware update failure in IBMHID and IBMTT modes, seen with particular versions of scanner firmware.
Version 4.4.1-34 - 07/2023
-
Enhanced JPOS driver
- Bug fix - Fixed issue that incorrectly appended a Label ID for NCR label with barcode type ISSN.
- Bug fix - Fixed issue relevant to error arguments (locus and response) in JPOS read weight error events.
- Sample App Security fix - Updated library "xercesImpl.jar" used in JPOS Sample application from v2.11.0 to v2.12.2 to resolve security vulnerabilities exposed from v2.11.0.
- Sample App Bug fix - Device enable button now gets updated upon enabling auto device enable (button) in JPOS scale.
- Sample App Bug fix - Barcode name now correctly displayed for Han Xin Code.
- Command Line Utility (CLU) - Bug Fix - Addressed memory allocation issue with "reboot" and "getattribute" commands.
Version 4.4.1-32 - 04/2023
- Active Focus Manager (AFM) Module - Alpha release for customer evaluation. Available for download separately, not bundled with the SDK.
-
Enhanced Driver Data Formatting (DDF) module - Alpha release for customer evaluation - Added support to incorporate ATL key combinations using the Driver
- Data Formatting (DDF) module. This functionality enables an ALT key combination to be added to barcode data when using Simulated HID Keyboard.
- Configuring this capability is located in the CoreScanner configuration xml file.
- An example of this capability is sending "ALT [ + Data + Enter"; also "ALT [ + Data + TAB".
- This initial implementation can only support sending ALT + one key sequence like "ALT [".
- This new ALT key capability supports modifying data using a Prefix only (Suffix with ALT key is not supported).
-
Command Line Utility (CLU) - Initial release. This utility provides scripting control of Zebra scanner. Supported functionality includes:
- Reboot of a scanner
-
Parameter Control
- Param Get and Set
- 123Scan config file consumption
- F/W update
-
Enhanced JPOS driver
- Bug fix in Sample App - Fixed error message incorrectly displayed in JPOS Sample application when Zero Scale command is called and weighing item below 30 grams.
- Update JPOS driver to fire Scale status update events whenever a status updates and a weight change is detected.
- Bug fix in Sample App - Made the display format for scale weight consistent in the sample application for Read Weight, Live Weight and Direct IO NCR Live Weight calls.
- Bug fix in JPOS Sample App - Fixed application lockup if enabling both live weight and auto disable simultaneously.
Version 4.4.1-31 - 01/2023
- Enhanced IoT Connector - Added support for C98. Note C98 is a C++ compilation standard.
-
Added IoT connector support for following distributions.
- RedHat 7.4 64bit
- CentOS 7.9 64bit
- Ubuntu 14.04 64bit
- Added "Simulated HID Keyboard" support to CoreScanner.
-
Added "DDF" (Driver Data Formatting) support to CoreScanner.
- DDF enables driver-based data formatting like adding an Enter or Tab key to be appended to scanned data before its transmission to a host.
- DDF (Driver Data Formatting) is different than ADF (Advanced Data Formatting). DDF is performed by Zebra's CoreScanner Driver versus ADF is performed within the scanner's firmware.
- DDF is supported over "Simulated HID Keyboard" using the following comm interfaces: SNAPI, IBM HandHeld, IBM TableTop.
Version 4.4.1-30 - 10/2022
-
Enhanced SDK Sample Application,
- Added Page motor support to the SDK Sample Application.
- Now the Scale tab is disabled when the connected device is not a Zebra scale.
- Bug fix - Resolved inconsistency in “get all RSM values” responses.
-
Enhanced JPOS driver
- Enhanced driver to support NCR requested “HealthCheck” label IDs.
- Bug fix - “Get Error Response” API now returns the correct error on Read Weight in Scale.
- Minor UI optimizations in the JPOS Sample Application for Windows.
- Enhanced firmware update in non-bulk mode to generate continuous firmware update events in SDK. Note bulk mode already works this way.
Version 4.4.1-29 - 05/2022
-
Enhanced JPOS driver,
- Bug fix, ReadWeight events now reported correctly when DataEventEnabled is false and LiveWeight is true.
- Enhanced driver to support all NCR requested “ScanData” label IDs.
Version 4.4.1-28 - 04/2022
- Enhanced IoT Connector capabilities - Added support for logging scanner details where Global Unique Identifier (GUID) is invalid.
- TGCS support - add from Ken's email after Leads approve.
-
Enhanced Toshiba Global Commerce Solutions (TGCS) POS system support.
- JPOS driver enhanced to support System Management Information calls from TGCS POS systems.
- Corescanner enhanced to support TGCS' CIM Service Provider = “UPOS_BarcodeScanner” queries.
- Bug fix - Resolved issue in firmware update failure with DS9908 and DS8178 scanner models.
Version 4.4.1-27 - 01/2022
- Logging Agent renamed “IoT Connector”.
-
Enhanced JPOS driver,
- Fixed rarely seen JPOS statistics retrieval issue on scanners.
Version 4.4.1-24 - 10/2021
- Added support for SLES 15 SP3 (64bit), Ubuntu 21.04 (64bit), Debian 10.10 (32bit and 64bit).
-
Enhanced JPOS Driver
- Added support to execute DirectIO commands without claiming the device.
- JPOS sample application enhancement to display the "Live Weight" and the logs on live weight status update events.
- Enhanced logging in JPOS driver including access to barcode data, power state, scale weight, and what API calls have been made.
-
Enhanced Logging Agent capabilities
- Added support for logging of operating system environment variables like "host PC name". The environmental variable check is performed real time on each logging occurrence.
- Added support for real time logging via a JSON call to cloud-based consoles like Splunk.
Version 4.4.1-19 - 04/2021
- Added support for CentOS 7.9 (64bit).
- Enhanced JPOS driver v1.14 to include support for PNP events for both Scanner and Scale.
- Enhanced the SDK’s UI sample application to include Scale functionalities (Read Weight, Zero Scale, Reset Scale).
- Bug fix - The JPOS driver v1.14 for code 49 now returns the correct Symbology types when the Zebra scanner is in IBM Hand-Held or IBM Table-Top host modes.
Version 4.4.1-16 - 01/2021
- Enhanced log file - Resident scanner firmware update status (STATUS_FW_SWCOMP_RESIDENT) added to the log files.
- Enhanced console-based sample application for CoreScanner - The console app now shows call success and failure (Logging API return values) and output XML.
- Bug fix - The MS4717 now properly switches from HIDKB host mode to another com protocol and back.
- Bug fix - The CoreScanner now properly returns the valid status codes for “invalid firmware file” and “failed to read DAT file”.
- Bug fix - The SDK sample application now properly returns an error when launched without running the CoreScanner.
Version 4.4.1-15 - 10/2020
- Common JPOS driver bundled in both Linux and Windows SDKs. Since same driver, same features are now supported across both Linux and Windows.
- JPOS driver update. Removed Apache Xerces XML parser dependency from the Zebra JPOS Service Object (SO).
Version 4.4.1-11 - 07/2020
- Added supports for Ubuntu 20.04 (64bit) and CentOS 8.1 (64bit).
- Logging Agent bundled with Linux SDK.
- The Logging Agent allows a 3rd party management console to track scanner information including the scanner’s health by parsing a Logging Agent generated log file.
- The Logging Agent is configurable for example it can be output for all devices (1,000s of log files) or just devices that meet a specific condition like failed a firmware update (a few log files).
- The Logging Agent can document the following information:
- Asset information
- Statistics for example battery charge level or UPCs scanned
- Firmware failures and or firmware success
- Parameter value(s) changed. Achieved by tracking parameter 616 (config file name changed to “Modified”)
- Added support for composite barcode types.
- Bug fix - Sample application freeze resolved on scanner PNP.
- Bug fix - Sample application RSM attributes list shows the correct permissions for each attribute.
Version 4.4.1-8 - 04/2020
- Added option for enabling new Zebra HID API instead of using native OS provided HID API. Zebra HID API enabled through a configuration setting, switching from libusb to hidraw.
- Add support for additional distributions: Raspbian 8 and ARM7L (32-bit ARM processor). Note this Linux OS runs on Raspberry PI 3.0 hardware.
- Bug fix - Resolved app responding delay by sending the Direct I/O commands using the HID API directly from the comlib to the scanner.
- Bug fix - Synchronization block introduce when consuming the events from CoreScanner to JPOS driver. Otherwise, the single core POS system is missing different events from different logical devices (JPOS)
Version 4.4.1-4 - 01/2020
- Added ability to discover, communicate and manage a third level cascaded device. The SDK now supports connecting cordless scanners like a DS2278 and cradle to a MP7000. The MP7000 is connected to the host.
Version 4.4.1-2 - 10/2019
- Added "DotCode" and "GridMatrix" symbology support to JPOS and SDK Sample Applications. Note the Linux SDK already supported these symbologies.
- Added Java 12 UI enhancements to JPOS Sample Application. Note no change required in the JPOS driver.
Version 4.4-0-18 - 08/2019
- Added Scale Live Weight event support for Multi-Plane scanners.
- Vendor specific capability, ‘CapStatusUpdate’ enabled in JPOS Scale driver.
- Implemented ‘StatusNotify’ property in JPOS driver.
Version 4.4.0-15 - 06/2019
- Added get next Attribute RSM command support in CoreScanner.
Version 4.4.0-14 - 06/2019
- "EAN13 Supplementary of 5" symbology support added into JPOS Sample Application.
Version 4.4.0 - 03/2019
- Added JPOS 1.14 standard compatibility for the JPOS driver.
- Introduced a JPOS based asset query capability (model #, serial #, date of manufacture, firmware version).
Version 4.3.3 - 01/2019
- Enhanced Linux log file format to mirror Zebra’s Windows SDK logging format
-
Added ability to customize logging capabilities via the CoreScanner configuration file. Settings include,
- Log file storage path
- Number of stored log file. For example, save the last 50 files.
Version 4.3.1 - 08/2018
- Added support for JPOS Scale Asynchronized Read Weight -1 (forever) timeout support.
- Added support for Intelligent Document Capture (IDC).
- Added ability to specify an on board udev library using the CoreScanner’s configuration file instead of the system default.
Version 4.2.4 - 04/2018
- JPOS Scale Read Weight Asynchronized mode support.
-
JPOS Statistics reporting support for Scale.
Note C++ applications cannot be compiled with C++ 11 based compilers without setting _GLIBCXX_USE_CXX11_ABI macro to 0. Below definition will be used to set ABI to the old C++ version.
#define _GLIBCXX_USE_CXX11_ABI 0
Version 4.1.11 - 01/2018
- Host variant switching from CDC to management modes.
Version 4.1.0 - 10/2017
- Support for custom PIDs.
Version 4.0.0 - 05/2017
- Source tarball.
- Install Verifier application added.
Version 3.0.0 - 08/2016
- IBM TT, IBM HID, SNAPI firmware download support.
- SNAPI fast firmware downloads support.
- SNAPI Imaging and Video capturing.
- API events like PNP events.
- Detecting HIDKB devices.
Version 2.0.0 - 02/2016
- Existing drivers were rebranded from Motorola to Zebra.
Version 1.3.0 - 08/2015
- Supports for Ubuntu 14.04, Ubuntu 12.04, SLES 11, CentOS 6.3 distributions.
- Concurrent application support for Scanner and Scale of MP6200 in JPOS.
- Cascaded device support for MP6200, Presentation Cradle and Standard Cradle.