Appearance
Vision: barcodes and QR codes
Last updated
License feature: Machine VisionThe Barcodes & QR codes tool publishes what codes say, not how many parts there are. It reads Code 128, Code 39, EAN, UPC, QR, DataMatrix, PDF417, Aztec and other common symbologies. If the appliance's barcode component is missing, only QR codes are read.
Tags
All under the tool's prefix — a tool with prefix label publishes label/code.
| Tag | Holds |
|---|---|
code | The first code, in reading order (or the one a slot rule picked) |
code_2 … code_10 | The rest, one per tag, up to Codes to publish |
codes | Every code read, separated by a vertical bar with a space either side |
format | The symbology of the first code — Code128, QRCode, DataMatrix, EAN13 … |
count | How many codes were read (after filters) |
Positions with no code read empty rather than disappearing, so a screen or script bound to code_3 does not break on a label with two codes. Codes are ordered top to bottom, then left to right; codes on the same row sort left to right even when their tops differ by a pixel, so code is the same one on every frame.
Settings
| Setting | Default | Range | What it does |
|---|---|---|---|
| Upscale | 1 | 1–4 | Enlarges the region before reading. Small or low-contrast codes often fail at native size and read at 2 |
| Codes to publish | 5 | 1–10 | How many code tags the device has. Takes effect on Save |
| Starts with | empty | text | Ignore codes that do not start with this. A UPS tracking number always starts 1Z |
| Ends with | empty | text | Ignore codes that do not end with this |
| Contains | empty | text | Ignore codes that do not contain this anywhere |
| Code type | empty | text | Only this symbology, e.g. Code128, QRCode, DataMatrix, EAN13. Often the cleanest way to pick one code |
| Min length | 0 | 0–64 | Ignore codes shorter than this. 0 for no limit |
| Max length | 0 | 0–64 | Ignore codes longer than this. 0 for no limit |
The filters apply to the whole tool before anything is assigned to a tag; they combine (all must pass) and are not case-sensitive. Codes a filter rejects are not counted and do not appear in codes.
Which code goes in which tag
Under Which code goes in which tag there is one row per code tag (code, code_2 …), marked any or by rule. Open a row to give it its own Starts with, Ends with, Contains, Code type, Min length and Max length. The × clears a row's rule.
A slot with a rule claims the first code that matches it, wherever it is on the label. Slots without a rule then take whatever is left, in reading order. A code is claimed once.
Example — a shipping label with a tracking number, a part number and a QR code:
| Slot | Rule | Result |
|---|---|---|
code | Starts with 1Z | The tracking number, wherever it is printed |
code_2 | Code type Code128, Min length 8, Max length 8 | The eight-character part number |
code_3 | any | Whatever is left — here the QR code |
Drawing a region round the wanted code does the same job geometrically and decodes faster. Use a region if the code is always in the same place, a rule if it moves.
Pass / fail
| Option | Passes when |
|---|---|
| A code must be read | At least one code (after filters) was decoded in the region |
| A code must contain | This text appears in codes — for example LOT-. Case-sensitive, unlike the filters |
With both empty and unticked, a judged barcode tool reports as not judged.