AV Foundation: Code 39 Recognition Confusion

Originator:oliver.drobnik
Number:rdar://18566595 Date Originated:
Status:Closed Resolved:
Product:iOS Product Version:iOS 8.0.2 (12A405)
Classification:Serious Bug Reproducible:Always
 
Summary:
If you enable both versions of Code39 detection (with and without Mod43 check digit) AV Foundation always reports the scanned barcode as Code39, regardless if you scan a version with or without check digit. The check digit is then output as extra character.

Steps to Reproduce:
1. Set up a metadata output to scan for AVMetadataObjectTypeCode39Code and AVMetadataObjectTypeCode39Mod43Code
2. Create a Code39mod43 with contents "CONTENTS"
2. Scan a Code39 barcode with Mod43 check digit

Expected Results:
- code should be reported as "org.iso.Code39Mod43"
- code content should be "CONTENTS"

Actual Results:
- code is reported as "org.iso.Code39"
- code contents is "CONTENTSA" (extra character)

Version:
iOS 8.0.2 (12A405)

Notes:
If you remove the AVMetadataObjectTypeCode39Code type from the metadata output, then the scanned barcode is reported as described in expected results.

So the detection order might be the wrong way around. The problem is - as a developer - I have way to know which of the both Code39 variants was actually scanned. And thus I wouldn't know if I can disregard the extra character.

Configuration:
iPhone 5S

Comments


Please note: Reports posted here will not necessarily be seen by Apple. All problems should be submitted at bugreport.apple.com before they are posted here. Please only post information for Radars that you have filed yourself, and please do not include Apple confidential information in your posts. Thank you!