barnhill / barcodelib

C# Barcode Image Generation Library
Apache License 2.0
744 stars 239 forks source link

Codabar, encodings for B and C are swapped #167

Closed rob313663 closed 1 year ago

rob313663 commented 1 year ago

Hi!

Codabar_Code.Add('B', "1010010011");//"101011001011"); Codabar_Code.Add('C', "1001001011");//"110101100101");

I made a Codabar with the "Barcode Encoder" program included in BarcodeLib with the content "A3117013206375B". Then I read that with an Zebra TC52 device (built-in 2D code reader).

It outputs "A3117013206375C". Investigating this I found that the bit patterns for B and C has been swapped:

Codabar_Code.Add('B', "1010010011");//"101011001011"); Codabar_Code.Add('C', "1001001011");//"110101100101");

They should be: Codabar_Code.Add('B', "1001001011"); Codabar_Code.Add('C', "1010010011");

/rob

barnhill commented 1 year ago

fixed this in 3.0.2 release thats now published and awaiting approval from MS

barnhill commented 1 year ago

Let me know if you find any more like this. Thank you for contributing and making this library better!

superybq commented 1 year ago

Let me know if you find any more like this. Thank you for contributing and making this library better!

Uppercase B and C have been corrected, but lowercase has not fixed.

BarcodeStandard/Symbologies/Codabar.cs

Codabar_Code.Add('B', "1001001011");
Codabar_Code.Add('C', "1010010011");

Codabar_Code.Add('b', "1010010011");
Codabar_Code.Add('c', "1001001011");