Skip to content

Commit 4ad9a84

Browse files
authored
Update avoid-incorrect-barcode-results.md
1 parent 4d95244 commit 4ad9a84

File tree

1 file changed

+37
-0
lines changed

1 file changed

+37
-0
lines changed

barcode-reader/general/avoid-incorrect-barcode-results.md

Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,3 +10,40 @@ needAutoGenerateSidebar: false
1010

1111
- One method is to raise the value of [minResultConfidence](https://www.dynamsoft.com/barcode-reader/docs/web/programming/javascript/api-reference/interface/RuntimeSettings.html#minresultconfidence) of the `RuntimeSettings` to a value of 50 or higher. It is set to 30 by default.
1212
- If the issue has to do with the length of the text result, you can try setting a minimum length for the barcode text(s) that are returned by the SDK. By setting the [minBarcodeTextLength](https://www.dynamsoft.com/barcode-reader/docs/web/programming/javascript/api-reference/interface/RuntimeSettings.html#minbarcodetextlength) property of the `RuntimeSettings`, the SDK can ignore results that are consistently coming out shorter than expected.
13+
---
14+
15+
> **Notice (Temporary Issue)**
16+
> This is a known issue in the current release and will be fixed in the next version.
17+
>
18+
> As a temporary solution, please set `IncludeTrailingCheckDigit` to `0` in the `BarcodeFormatSpecification` for Code128.
19+
> This will prevent the SDK from returning the trailing check digit.
20+
21+
### CODE_128 decoding returns an extra byte?
22+
23+
When using DBR v11, you may notice that decoding a **CODE_128** barcode returns one extra byte at the end if you call `item.get_bytes()`.
24+
25+
**Cause**
26+
By default, DBR includes the trailing check digit for CODE_128 in the decoded byte results.
27+
28+
**Solution**
29+
Set `IncludeTrailingCheckDigit` to `0` in the `BarcodeFormatSpecification` for Code128.
30+
31+
**Example JSON Configuration**
32+
33+
```json
34+
{
35+
"BarcodeFormatSpecificationOptions": [
36+
{
37+
"Name": "bfs1",
38+
"BarcodeFormatIds": [
39+
"BF_CODE_128"
40+
],
41+
"MinResultConfidence": 30,
42+
"RequireStartStopChars": 1,
43+
"ReturnPartialBarcodeValue": 1,
44+
"VerifyCheckDigit": 0,
45+
"IncludeTrailingCheckDigit": 0
46+
}
47+
],
48+
#...Other Settings
49+
}

0 commit comments

Comments
 (0)