Skip to content
This repository has been archived by the owner on Sep 4, 2019. It is now read-only.

Barcode Reader decodes Content incorrect #47

Open
Anollya opened this issue May 16, 2015 · 9 comments
Open

Barcode Reader decodes Content incorrect #47

Anollya opened this issue May 16, 2015 · 9 comments

Comments

@Anollya
Copy link

Anollya commented May 16, 2015

Hello,

i use the Barcode Reader Source from Github (Github link). The App works fine but i´ve one Barcode when i want it to scan, the App decodes the content incorrect.

Is this an API 10.3.1 bug? Because the Android App QR Droid decode the Data Matrix Code fine.

Here is the Barcode:
https://www.dropbox.com/s/bcc02orzwyybpv3/BC.jpg?dl=0
The correct decoded content is:
1P6SL3120-1TE15-0AA4+ST-F56076108

From the Blackberry Barcode Reader decoded content:
https://www.dropbox.com/s/ypan9bhir1f1uus/BB_BC_Content.JPG?dl=0

Additional Information:
The Data Matrix Code is encoded from a CAB Printer.
Programming Manual:
https://www.cab.de/media/pushfile.cfm?file=153

Page 134:
The encoding and decoding process of Data Matrix is very complex and several
methods have been used for error correction in the past. ECC200 is the newest
and most standard version of data matrix error correction. It supports advanced
encoding and error checking with Reed Solomon error correction algorithms.
These algorithms allow the recognition of barcodes that are up to 60% damaged.

How can i fix the issue or who can fix the issue? Is the an API 10.3.1 bug?

@seanmcveigh
Copy link

The barcode scanning library used on BB10 is ZXing. I cannot recall the version at the moment (perhaps someone else can dig this up), but you may wish to check the state of the upstream codebase to see if it properly supports this standard. They have had bugs before.
You could consider using the upstream library directly in your code if there happens to be a bug that is fixed in a newer version.

@Anollya
Copy link
Author

Anollya commented May 20, 2015

Hello seanmcveigh,

thank you for your answer.
I try the custombarcodescanner (https://github.com/blackberry/Cascades-Samples/tree/master/custombarcodescanner), the decoded content is incorrect too.
The Smart Tag app decodes also incorrect.

Another DataMatix Codes works fine.
But when i try a Barcode generator (Data: 1P6SL3120-1TE15-0AA4+ST-F56076108), the decode fail again...but the incorrect decoded content is a little different from the first post above.
http://barcode.tec-it.com/barcode-generator.aspx?group=BCGroup_2D&barcode=DataMatrix

Can fix the issue the Cascades-Samples Community or only Blackberry?

@seanmcveigh
Copy link

the custombarcodescanner and smart tags both use the same ZXing library. this is most likely a bug in the ZXing decoder and you can confirm this by trying the ZXing software on a different platform, like a PC, etc. in fact, there is a web version here -> http://zxing.org/w/decode.jspx (I am just not sure how recent that version is).

The home for ZXing is here: https://github.com/zxing/zxing
You should be able to try the code in some form or another, or contact the authors.

@seanmcveigh
Copy link

Note: that this could also be a recently fixed bug, in which case if you can find the date or version when it was fixed, we may be able to pull the fixed version into the blackberry platform.

@Anollya
Copy link
Author

Anollya commented May 22, 2015

I change the barcode color because the picture is to dark for the photo upload on http://zxing.org/w/decode.jspx. Of course the Blackberry still decodes the barcode incorrect.
white&black Barcode:
https://www.dropbox.com/s/cu7uucbvjm3q2qi/BC1.jpg?dl=0

http://zxing.org/w/decode.jspx decodes the photo fine.
Result: 1P6SL3120-1TE15-0AA4+ST-F56076108

Then i try the ZXing.net version.
http://zxingnet.codeplex.com/
It works fine too.
Release Notes:

  • changes of the java version are reflected until 2014/03/13

I think all ZXing versions higher then 2014/03/13 should be work.

@timwindsor
Copy link
Contributor

The version of ZXing that's on device definitely predates that time, so the best solution is to build in a new version. I'd like to do that myself, but I've got too many other things going on right now, so I won't be able to get to it for quite some time. Last time I looked at ZXing, they weren't maintaining the C++ port, so you may need to look through the repo history to find the last version they had. It should be fairly recent, but may not keep up with future changes.

@seanmcveigh
Copy link

Thanks for checking!
Tim, perhaps you can at least open a ticket internally to track this so we don't lose sight of it.

Anollya, have you tried loading any Android barcode scanners? They would presumably use a later captive version of ZXing. If you are developing an app, that is another valid route to look into, since BB10 supports running Android apps.

@Anollya
Copy link
Author

Anollya commented May 23, 2015

yes, i tried QR Droid (https://play.google.com/store/apps/details?id=la.droid.qr).
The app decodes the barcode fine on BB10.

@Anollya
Copy link
Author

Anollya commented May 23, 2015

I see on the ZXing Homepage (https://github.com/zxing/zxing) a third-party c++ port.
It seems that looks like newer as the old official c++ port.

zxing-cpp port to C++ (forked from the deprecated official C++ port)
https://github.com/glassechidna/zxing-cpp

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants